On Aug 20, 2010, at 1:53 PM, Laetitia Schmid wrote:
Hi Richard,
thank you very much. I got the results I needed. But I am still
interested to find out how it would work with a if-else function in
this context.
lapply(para, function(x) if (max(x) >= 4 ){1} else {0})
--
David
Best,
Laeti
Hi Richard,
thank you very much. I got the results I needed. But I am still
interested to find out how it would work with a if-else function in
this context.
Best,
Laetitia
Am 20.08.2010 um 23:40 schrieb RICHARD M. HEIBERGER:
> tmp <- "VariablePARPlot1Plot2
> tmp <- "VariablePARPlot1Plot2
Plot3Plot4
+ ParasiteA3114
+ ParasiteB1235
+ ParasiteC2113
+ ParasiteD2
Hi R people!
I am looking for some suggestions writing an if-else function.
The idea is to characterize different plots containing counts of
variables (here parasites). If a plot has a count equal or higher than
4 for any parasite the function should return a 1 else a 0. Later I
can loop the
Hello everyone,
I would like to use the "if" statements and I was thinking sth like
If () {} else{ if() {} else{} }
Is this a possible solution and is there any syntax error?
Could anyone give me some advice? Many thanks.
--
View this message in context:
http://www.nabble.com/If-Else-Funct
5 matches
Mail list logo