Displaying 6 results from an estimated 6 matches for "catrsw".
Did you mean:
catrow
2012 Aug 17
7
Remove several numbers from a sequence
Can anyone tell me how to remove several numbers for a sequence. For example:
xx<- c(1,5,7,10)
yy<-seq(1,10,1)
how do I get take xx away from yy to get the new sequence
2,3,4,6,8,9
Many thanks in advance
--
View this message in context: http://r.789695.n4.nabble.com/Remove-several-numbers-from-a-sequence-tp4640630.html
Sent from the R help mailing list archive at Nabble.com.
2012 Aug 05
4
find date between two other dates
Hi,
I am trying to assign "Season" values to dates depending on when they occur.
For example, the following dates would be assigned the following "Season"
numbers based on the "season" intervals detailed below in the code:
ddate Season
29/12/1998 20:00:33 1
02/01/1999 05:20:44 2
02/01/1999 06:18:36 2
02/02/1999
2012 Oct 22
3
Remove records from a large dataframe
Hi, I am trying to remove a series of records from a large dataframe. The
script I have written works fine but takes a long time to run. Can anyone
suggest a quicker way to do this?
Here is an example of the code I've written. The end result of this bit of
code would be a dataframe with any records relating to ID 1 or ID 4 removed:
#dataframe
id <- c(1,1,1,1,2,2,2,2,2, 3,3,3, 4,4)
2012 Aug 08
1
map axis on projected shapefiles
Hi,
I have overlayed 2 projected shapefiles using the "plot" function.
When I plot them the numbers next to the x-axis ticks are printed in
scientific format (e.g. -4e+05, -3e+05,...,), and the problem is these dont
match up to the projected point locations I also wish to overlay from my
dataset. For example, according to the x-axis ticks the prime meridian (0?)
is in totally the
2012 Jul 18
2
conditional increase by increment
I am trying to assign increasing trip numbers to a binary variable ("land";
1=home and 0=away) where a string of 1's shouldn't increment the trip_no
more than once.
For example; based on
land<-c(0,0,0,0,1,1,1,0,0,0,1,1,0,0,0,0)
the "trip_no" sequence produced should be 1,1,1,1,2,2,2,2,2,2,3,3,3,3,3,3
This is as far as I can get but Im stumped. In addition I
2012 Oct 21
2
conditional value assignment
Hi,
I am trying to assign values to records based conditionally on other records
within a dataframe. For example, in the following dataframe the "NA" value
in dat$age would be replaced if the age status for that individual and
specific year can be found in another record. Ideally this would then also
assign the same age status if the individual is recorded in a later year.