[R] Analyzing large files faster

2012-06-12 Thread mousy0815
I'm trying to analyze the following data set (sample): "ID""adj.P.Val" "logFC""Gene.symbol" "1419156_at""5.32e-12" "2.6462565" "Sox4" "1433575_at""5.32e-12" "3.9417089" "Sox4" "1428942_at""2.64e-11" "3.9163618" "Mt2" "1

Re: [R] Why does the graph converge?

2011-08-17 Thread mousy0815
Well I didn't expect it to converge because the first three lines (black, orange and turquoise) didn't converge. I was trying to find a condition in which it would be more efficient for T cells to spend less time in the lymph nodes, and I did when you increase the number of DC's per lymph node (s

[R] Why does the graph converge?

2011-08-16 Thread mousy0815
I have a set of functions: Probability <- function(N, f, w, b, l, n, q) { #N is the number of lymph nodes #f is the fraction of Dendritic cells (in the correct node) that have the antigen #w is time in terms of hours #b is the starting position (somewhere in the no

Re: [R] An infinite recursion error please explain!

2011-07-23 Thread mousy0815
edit: I fixed it; apparently I needed to change the ceiling(w/q) to w%/%q, though I'm not really sure why that made such a difference. -- View this message in context: http://r.789695.n4.nabble.com/An-infinite-recursion-error-please-explain-tp3688260p3689621.html Sent from the R help mailing list

Re: [R] An infinite recursion error please explain!

2011-07-23 Thread mousy0815
In response to the second question about the placement of D<=t, there are two instances of it: once after the comment "starts inside node" (After the line with the comment "start & end in first node") and one after "starts outside node." Did that answer the question? I don't know if this helps, b

[R] An infinite recursion error please explain!

2011-07-23 Thread mousy0815
Probability <- function(N, f, w, b, y, t, q) { #N is the number of lymph nodes #f is the fraction of Dendritic cells (in the correct node) that have the antigen #w is time in terms of hours #b is the starting position (somewhere in the node or somewhere in the gap

[R] exponent function help??

2011-07-12 Thread mousy0815
I'm trying to make a function that will output the exponent... so f2(2,2) = 4 and f2(2,3)=8. But I don't want to just use the x^n function, I want to do it another way, and without a recursion. I did the follow code but for some reason it doesn't work. Help please? f2 <- function(x, n) #without r

[R] Explain how it gets back out?

2011-07-12 Thread mousy0815
Probability <- function(N, f, m, b, x, t) { #N is the number of lymph nodes #f is the fraction of Dendritic cells (in the correct node) that have the antigen #m is the number of time steps #b is the starting position (somewhere in the node or somewhere in the gap b

Re: [R] user input.

2011-07-11 Thread mousy0815
try something like: cat("\n","Enter your number","\n") # prompt y<-scan(n=1) #scans the line before ? perhaps? -- View this message in context: http://r.789695.n4.nabble.com/user-input-tp3660993p3661031.html Sent from the R help mailing list archive at Nabble.com. ___

Re: [R] Summation resulting in a list?

2011-07-11 Thread mousy0815
Use the tapply() function as in tapply(b,m,sum) HTH, Daniel Don't "b" and "m" have to be the same length then? What if they're not? And would I just put the tapply() instead of everything else in my summing function? (Sorry! I'm kind of newbie at this -_-;) -- View this message in context: h

[R] Summation resulting in a list?

2011-07-11 Thread mousy0815
Probability <- function(N, f, m, b, x, t) { #N is the number of lymph nodes #f is the fraction of Dendritic cells (in the correct node) that have the antigen #m is the number of time steps #b is the starting position (somewhere in the node or somewhere in the gap b

Re: [R] problems with ifelse??

2011-07-10 Thread mousy0815
This fixed my problem thanks. -- View this message in context: http://r.789695.n4.nabble.com/problems-with-ifelse-tp3658498p3658543.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing list https://stat.ethz.ch/

[R] problems with ifelse??

2011-07-10 Thread mousy0815
I have the following code to determine the probability of a t-cell encountering an antigen after "m" steps. probability <- function(N, f, m, b, x, t) { #using ifelse instead of if/else #N is the number of lymph nodes #f is the fraction of Dendritic cells (in the correct node) that