Dear all I have two 10*10 matrixes and I would like to compare theirs contents. By the word content I mean to check visually (not with any mathematical formulation) how similar are the contents. I also know edit that prints my matrix in the scree but still one edit blocks the prompt to launch a second edit() screen. What is the best way to compare these two matrices? I would like to thank you in avdance for your help Regards Alex
> Dear all I have two 10*10 matrixes and I would like to compare > theirs contents. By the word content I mean to check visually (not > with any mathematical formulation) how similar are the contents.If they are really only 10x10 you can simply print them both to the screen and look at them. I'm not sure what else you could do if you are not interested in a specific distance emasure etc. cu Philipp -- Dr. Philipp Pagel Lehrstuhl f?r Genomorientierte Bioinformatik Technische Universit?t M?nchen Wissenschaftszentrum Weihenstephan Maximus-von-Imhof-Forum 3 85354 Freising, Germany http://webclu.bio.wzw.tum.de/~pagel/
On 04.03.2011 08:42, Alaios wrote:> Dear all I have two 10*10 matrixes and I would like to compare theirs contents. By the word content I mean to check visually (not with any mathematical formulation) how similar are the contents. > > I also know edit that prints my matrix in the scree but still one edit blocks the prompt to launch a second edit() screen. > > What is the best way to compare these two matrices? > > I would like to thank you in avdance for your helpSee ?image. Uwe Ligges> Regards > Alex > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.
I sometimes use the enclosed sideBySide() function to look at two printouts (of any sort of objects) in parallel. Perhaps that would help. sideBySide <- function (a, b, argNames) { oldWidth <- options(width = getOption("width")/2 - 4) on.exit(options(oldWidth)) if (missing(argNames)) { argNames <- c(deparse(substitute(a))[1], deparse(substitute(b))[1]) } pa <- capture.output(print(a)) pb <- capture.output(print(b)) nlines <- max(length(pa), length(pb)) length(pa) <- nlines length(pb) <- nlines pb[is.na(pb)] <- "" pa[is.na(pa)] <- "" retval <- cbind(pa, pb, deparse.level = 0) dimnames(retval) <- list(rep("", nrow(retval)), argNames) noquote(retval) } Try: > x1 <- matrix(sort(rnorm(100)),10,10) > x2 <- matrix(sort(rnorm(100)),10,10) > sideBySide(x1,x2) Bill Dunlap Spotfire, TIBCO Software wdunlap tibco.com> -----Original Message----- > From: r-help-bounces at r-project.org > [mailto:r-help-bounces at r-project.org] On Behalf Of Alaios > Sent: Thursday, March 03, 2011 11:42 PM > To: R-help at r-project.org > Subject: [R] How two compare two matrixes > > Dear all I have two 10*10 matrixes and I would like to > compare theirs contents. By the word content I mean to check > visually (not with any mathematical formulation) how similar > are the contents. > > I also know edit that prints my matrix in the scree but still > one edit blocks the prompt to launch a second edit() screen. > > What is the best way to compare these two matrices? > > I would like to thank you in avdance for your help > > Regards > Alex > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. >
http://sch.co.jp/ エスシーエイチ http://sch.co.jp/ SCH http://sch.co.jp/ サッカー教室 神奈川 http://www.taisei-erc.co.jp/ 派遣 横浜 http://www.taisei-erc.co.jp/ 大成 http://www.taisei-erc.co.jp/ 人材派遣 横浜市 http://awachuobus.jp 徳島 バス http://awachuobus.jp 阿波 バス http://awachuobus.jp 徳島 観光 http://www.central-golf.jp/ 豊田 ゴルフ練習場 http://www.central-golf.jp/ 豊田 ゴルフ http://www.central-golf.jp/ トヨタ ゴルフ http://www.yazawa-h.jp/ 宮前区 市議会議員 http://www.yazawa-h.jp/ 川崎市 市議会議員 http://www.yazawa-h.jp/ 川崎 市議 http://matsuozaimokuten.com/ 佐賀 材木 http://matsuozaimokuten.com/ 佐賀 木材 http://matsuozaimokuten.com/ 材木 杭 -- View this message in context: http://r.789695.n4.nabble.com/How-two-compare-two-matrixes-tp3334795p3581574.html Sent from the R help mailing list archive at Nabble.com. [[alternative HTML version deleted]]