Re: [R] How to pool a group of samples and take the ave.

2007-11-12 Thread affy snp
Thanks Jim and Ben. Allen On Nov 12, 2007 3:43 PM, Benilton Carvalho <[EMAIL PROTECTED]> wrote: > it's defined in Biobase. > > > On Nov 12, 2007, at 3:30 PM, affy snp wrote: > > > Thanks Jim. It is way simple. Great. > > Is there any function like rowMedians() which > > could take the median valu

Re: [R] How to pool a group of samples and take the ave.

2007-11-12 Thread Benilton Carvalho
it's defined in Biobase. On Nov 12, 2007, at 3:30 PM, affy snp wrote: > Thanks Jim. It is way simple. Great. > Is there any function like rowMedians() which > could take the median value across samples? > > Allen > > On Nov 12, 2007 3:10 PM, jim holtman <[EMAIL PROTECTED]> wrote: >> Try something

Re: [R] How to pool a group of samples and take the ave.

2007-11-12 Thread jim holtman
you can use 'apply': apply(A[, 48:243], 1, median) On Nov 12, 2007 3:30 PM, affy snp <[EMAIL PROTECTED]> wrote: > Thanks Jim. It is way simple. Great. > Is there any function like rowMedians() which > could take the median value across samples? > > Allen > > On Nov 12, 2007 3:10 PM, jim holtman <

Re: [R] How to pool a group of samples and take the ave.

2007-11-12 Thread affy snp
Thanks Jim. It is way simple. Great. Is there any function like rowMedians() which could take the median value across samples? Allen On Nov 12, 2007 3:10 PM, jim holtman <[EMAIL PROTECTED]> wrote: > Try something like this: > > myAvg <- rowMeans(A[,48:243]) > B <- A[1:47,] / myAvg > > > On Nov 12

Re: [R] How to pool a group of samples and take the ave.

2007-11-12 Thread jim holtman
Was supposed to be: B <- A[,1:47] / myAvg On Nov 12, 2007 3:10 PM, jim holtman <[EMAIL PROTECTED]> wrote: > Try something like this: > > myAvg <- rowMeans(A[,48:243]) > B <- A[1:47,] / myAvg > > > On Nov 12, 2007 1:37 PM, affy snp <[EMAIL PROTECTED]> wrote: > > Dear list, > > > > Hi! I have a tab

Re: [R] How to pool a group of samples and take the ave.

2007-11-12 Thread jim holtman
Try something like this: myAvg <- rowMeans(A[,48:243]) B <- A[1:47,] / myAvg On Nov 12, 2007 1:37 PM, affy snp <[EMAIL PROTECTED]> wrote: > Dear list, > > Hi! I have a table A, 238304 rows and 243 columns (representing > samples). First of all, I would like to pool a group of samples > from 48th

[R] How to pool a group of samples and take the ave.

2007-11-12 Thread affy snp
Dear list, Hi! I have a table A, 238304 rows and 243 columns (representing samples). First of all, I would like to pool a group of samples from 48th column to 243rd column and take the average across them and make a single column,saying as the reference column. Second, I want to use each column o