[R] hi... problems about adjacency matrix

2010-07-08 Thread Gina Liao
Dear all, Hi, I have the problems about converting the matrix to adjacency matrix.Here's my example, ab cd e fa 1.000 0.4048823682 0.1228531 0.49046991 0.4945158868 0.307443317b 0.4048824 1.00

[R] Building an R package on MAC

2009-10-22 Thread Gina Liao
Hi, I'm trying to build R packages. My package name is TEST. (/Users/apple/Documents/R/TEST)I type something in Terminal.But it showed an error... applede-macbook-pro:~ apple$ R CMD BUILD TESTError: cannot change to directory 'anRpackage1' I don't know where is wrong...Hope that you could help

[R] Hi, a problem in using SNR

2009-08-16 Thread Gina Liao
Hello All, I'm going to select the differentially genes from my array by using SNR. There are two conditions:condition1:mean(group1)mean(group2)condition2:mean(group1)mean(group2) But I had a problem that how to write the code in R.I've searched in Internet, but I couldn't find anything.Hope

[R] problem about t test

2009-08-13 Thread Gina Liao
Hello, I have a data frame str(dat)'data.frame': 2 obs. of 30 variables it contains two information-two types of cancers:stage A(A1 to A10) and stage B(B1 to B20) ##totally 30 patients-2 sets of gene expression I'd like to find the lists for top 20 differentially expressed genes using

[R] the problem about normalize the data frame

2009-08-12 Thread Gina Liao
Hello, I'd like to normalize a data frame which are 45000 obs. of 212 variables.I want to normalize the data frame by each row. But I failed.Here is my R code, can you tell me where am I wrong? bb-function(normalize) (dat[i,]-min(dat[i,]))/(max(dat[i,])-min(dat[i,])) dat1-apply(dat,1,bb)

[R] hi, i have a problem in R

2009-08-05 Thread Gina Liao
Hi, I'm new to R language. There is a problem I couldn't understand. Hope you can answer my question. when i type for (i in 1:10){ + print(sample(9,4,replace=T)) +} and it shows ten of four numbers and how do I do to calculate the frequencies in each list? I know there is

Re: [R] hi, i have a problem in R

2009-08-05 Thread Gina Liao
Hi, I'm sorry i didn't say clearly. for (i in 1:10){ + print(sample(9,4,replace=T)) + } [1] 2 5 5 2 [1] 6 2 1 5 [1] 9 5 9 7 [1] 2 6 4 1 [1] 8 5 4 5 [1] 6 2 3 7 [1] 6 1 7 3 [1] 9 5 4 7 [1] 6 4 8 5 [1] 1 5 6 3 I mean when it shows these reults. Then, what should I do to show the top