search for: mycount

Displaying 5 results from an estimated 5 matches for "mycount".

Did you mean: mcount
2011 Nov 20
2
Adding two or more columns of a data frame for each row when NAs are present.
...t;Q20, Q21, Q22, Q23, Q24 + 0,1, 2,3,4 + 1,NA,2,3,4 + 2,1, 2,3,4") + yy Q20 Q21 Q22 Q23 Q24 1 0 1 2 3 4 2 1 NA 2 3 4 3 2 1 2 3 4 > x <- transform( yy, ############## Example 1 + mySum = as.numeric(Q20) + as.numeric(Q22) + as.numeric(Q24), + myCount = as.numeric(!is.na(Q20))+as.numeric(!is.na(Q21))+as.numeric(!is.na(Q24)) + ) + x Q20 Q21 Q22 Q23 Q24 mySum myCount 1 0 1 2 3 4 6 3 2 1 NA 2 3 4 7 2 3 2 1 2 3 4 8 3 > + x <- transform( yy, ################ Example 2 + myS...
2004 Feb 27
0
Re: [R] Is there a way to deactivate partial matching in R?
...tes the nonsense call makeoutput(outchannel=outcontent, whatever=whatevercontent) # I still find it difficult to write reliable code in R. # I am always afraid to run into something like > # simple example for dangerous partial list matching > > increment.counters <- function(..., mycounters){ + inclist <- list(...) + for (i in seq(along=inclist)) + mycounters[[names(inclist[i])]] <- mycounters[[names(inclist[i])]] + inclist[[i]] + mycounters + } > > mycounters <- list(leftcounter=0, rightcounter=0) > # intended use > mycounters <- increment.counters(leftcou...
2006 Apr 03
7
global variable - @@var
I tried to keep track of the number of access to a specific controller. I declared ''@@mycount = 0'' in the controller class. The methods in the controller will increment the @@mycount (@@mycount = @@mycount + 1) and print the value to the html page and show in the browser. The value is always 1, no matter how many times I access the controller and its action(s). Is this not t...
2006 Jan 17
8
Next Record
Okay, I know this will probably be a very easy question. But I am discovering that RonR makes just about everything easy. The problem is, it takes me a few hours to figure out that I can do it the easy way. I need to know how to move to the next record in a database. I want to format my out put in a table. For example, I want a 3 by 3 table. So record one goes in the first cell, record
2008 Dec 03
3
Help with maps
A few questions about maps... (1) How can I find a listing of the internal data sets that map() from the maps library contains? For example, "usa", "county", "state", "nz" all work. Are there any others? (2) Is there an easier, more generalized way to produce this (http://www.ai.rug.nl/~hedderik/R/US2004/ ) type of plot than this