Re: [R] How two compare two matrixes

2011-06-07 Thread tieunguyet
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]]

__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread Greg Snow
?View

-- 
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.s...@imail.org
801.408.8111


> -Original Message-
> From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
> project.org] On Behalf Of Alaios
> Sent: Friday, March 04, 2011 2:49 AM
> To: r-help@r-project.org; Philipp Pagel
> Subject: Re: [R] How two compare two matrixes
> 
> That's the problem
> Even a 10*10 matrix does not fit to the screen (10 columns do not fit
> in one screen's row) and thus I do not get a well aligned matrix
> printed.
> 
> This is that makes comparisons not that easy to the eye.
> From the other hand  with edit(mymatrix) I get scrolls so I can scroll
> to one row and see only the area  I want to focus in. Problem with edit
> is that it blocks cli and thus I can not have two edits running at the
> same time.
> 
> I would like to thank you in advacne for your help
> 
> Regards
> Alex
> 
> --- On Fri, 3/4/11, Philipp Pagel  wrote:
> 
> > From: Philipp Pagel 
> > Subject: Re: [R] How two compare two matrixes
> > To: r-help@r-project.org
> > Date: Friday, March 4, 2011, 8:04 AM
> > > 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/
> >
> > __
> > R-help@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.
> >
> 
> 
> 
> 
> __
> R-help@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.

__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread William Dunlap
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-boun...@r-project.org 
> [mailto:r-help-boun...@r-project.org] On Behalf Of Alaios
> Sent: Thursday, March 03, 2011 11:42 PM
> To: R-help@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@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.
> 

__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread P Ehlers

Alaios wrote:

That's the problem
Even a 10*10 matrix does not fit to the screen (10 columns do not fit in one 
screen's row) and thus I do not get a well aligned matrix printed.



I don't see why you would want to do this, but you
could always invoke two instances of R and create
one matrix in one and the other in the second.

Peter Ehlers


This is that makes comparisons not that easy to the eye.
From the other hand  with edit(mymatrix) I get scrolls so I can scroll to one 
row and see only the area  I want to focus in. Problem with edit is that it 
blocks cli and thus I can not have two edits running at the same time.

I would like to thank you in advacne for your help

Regards
Alex

--- On Fri, 3/4/11, Philipp Pagel  wrote:


From: Philipp Pagel 
Subject: Re: [R] How two compare two matrixes
To: r-help@r-project.org
Date: Friday, March 4, 2011, 8:04 AM

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/

__
R-help@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.






__
R-help@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.


__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread Mike Marchywka



> ?image
> ?matrix
> z<-matrix(rnorm(100),nrow=10)
> image(1:10,1:10,z)
> heatmap(z)
>





> Date: Fri, 4 Mar 2011 09:04:41 +0100
> From: p.pa...@wzw.tum.de
> To: r-help@r-project.org
> Subject: Re: [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.
>
> 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/
>
> __
> R-help@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.
  
__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread Philipp Pagel
On Fri, Mar 04, 2011 at 01:49:29AM -0800, Alaios wrote:
> That's the problem
> Even a 10*10 matrix does not fit to the screen (10 columns do not
> fit in one screen's row) and thus I do not get a well aligned matrix
> printed.
> 
> This is that makes comparisons not that easy to the eye.  From the
> other hand  with edit(mymatrix) I get scrolls so I can scroll to one
> row and see only the area  I want to focus in. Problem with edit is
> that it blocks cli and thus I can not have two edits running at the
> same time.

Hm - it does fit on my screen but if you're on a laptop... Maybe you
could write both matrices to files and compare them in an external
viewer (Excel, less, ...).

If I remember correctly, the object browser/data viewer of JGR allows 
editing several objects at once.

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/

__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread Uwe Ligges



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 help



See ?image.

Uwe Ligges




Regards
Alex

__
R-help@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.


__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread Alaios
That's the problem
Even a 10*10 matrix does not fit to the screen (10 columns do not fit in one 
screen's row) and thus I do not get a well aligned matrix printed.

This is that makes comparisons not that easy to the eye.
>From the other hand  with edit(mymatrix) I get scrolls so I can scroll to one 
>row and see only the area  I want to focus in. Problem with edit is that it 
>blocks cli and thus I can not have two edits running at the same time.

I would like to thank you in advacne for your help

Regards
Alex

--- On Fri, 3/4/11, Philipp Pagel  wrote:

> From: Philipp Pagel 
> Subject: Re: [R] How two compare two matrixes
> To: r-help@r-project.org
> Date: Friday, March 4, 2011, 8:04 AM
> > 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/
> 
> __
> R-help@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.
> 




__
R-help@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.


Re: [R] How two compare two matrixes

2011-03-04 Thread Philipp Pagel
> 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/

__
R-help@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.