similar to: aggredating date data

Displaying 20 results from an estimated 120 matches similar to: "aggredating date data"

2010 Mar 15
1
inner join sqldf
Hi, I have two dataframes that have some common columns. I would like to join them by the common columns prochi and prescribed_date as there are duplicate prochis but they will be made unique by date. I tried doing an inner join but that just duplicated the columns whereas I would like the information from the test_sql_tsf to fill the NAs in the test_sql_psd common columns. require(sqldf)
2010 Mar 12
7
sqldf not joining all the fields
Dear R users, I have two data frames that were read from text files as follows: x_data <- read.table("x.txt", header = TRUE, sep = "|", quote = "\"'", dec = ".",as.is = TRUE,na.strings = "NA",colClasses = NA, nrows = 3864284, skip = 0, check.names = TRUE,fill=TRUE, strip.white = TRUE,
2011 Jan 22
4
two apparent anomalies
(1) > a = c("a","b") > mode(a) [1] "character" > b = c(1,2) > mode(b) [1] "numeric" > c = data.frame(a,b) > mode(c$a) [1] "numeric" (2) > a = c("a","a","b","b","c") > levels(as.factor(a)) [1] "a" "b" "c" > levels(as.factor(a[1:3])) [1]
2011 Jan 21
3
data and parameters
(1) I have a master data frame that reads ClientID |date |value (2) I also have a control data frame that reads Client ID| Min date| Max date| control parameters The control data set may not have all client IDs . I want to use the control data frame on the master data frame to remove client IDS that don't exist in the control data set and for those that do, remove dates outside the
2011 Jan 26
2
hwo to speed up "aggregate"
I have > df quantity branch client date name 1 10 1 1 2010-01-01 one 2 20 2 1 2010-01-01 one 3 30 3 2 2010-01-01 two 4 15 4 1 2010-01-01 one 5 10 5 2 2010-01-01 two 6 20 6 3 2010-01-01 three 7 1000 1 1 2011-01-01 one 8 2000 2 1 2011-01-01
2010 Dec 25
4
need help with data management
I have a data frame that reads client ID date transcations 323232 11/1/2010 22 323232 11/2/2010 0 323232 11/3/2010 missing 121212 11/10/2010 32 121212 11/11/2010 15 ................................. I want to order the rows by client ID and date and using a black-box forecasting method create the data fcst(client,date of forecast, date for which forecast applies). Assume that I
2013 Apr 26
3
csv file with two header rows
Is there a way to use read.csv() on such a file without deleting one of the header rows? Thanks.
2011 Jan 11
1
question on aggregate
an example available on the net goes like > df identifier quantity 1 1 10 2 1 20 3 2 30 4 1 15 5 2 10 6 3 20 > aggregate(df$quantity, by=list(df$identifier), sum) Group.1 x 1 1 45 2 2 40 3 3 20 I'd like Group.1 to retain the name "identifier" and would like to
2010 Feb 05
1
reading csv files
the csv files are downloaded from a database and it looks like some character fields contain the CR-LF sequence within them. This causes R to see a new record/row and the number of rows it sees is different (usually higher) from the number of rows actually extracted. Any suggestions? Thanks.
2010 Dec 29
1
filling up holes
I have a data frame with three columns client ID | date | value For each cilent ID I want to determine Min date and Max date and for any dates in between that are missing I want to insert a row Client ID | date| NA Any help would be appreciated.
2011 Jan 12
3
Outputting csv file from dataframe with columns in a particular order
I have a dataframe with columns "ID",'date","estimate","actual" (but not necessarily in that order - I do a merge somewhere and that somehow messes up the order of the columns). How can I output it to a csv file with the columns in the order that I want? Thanks.
2005 Jun 22
1
Suggestion for the R Bugs web page
Hi all, I would like to recommend that the following text from the R Posting Guide be placed on the R Bug submission page in the section "Submit New Reports", which would read as follows: Submit New Reports You can submit new bug reports either using an online form by clicking on the button below or by sending email to r-bugs at biostat.ku.dk. Before you post a real bug report, make
2009 Nov 06
1
R splits character fields in a csv file
I download a csv extract from a database and use read.csv to read it from R and when there are large character fields with embedded blanks, slashes etc. - R often sees one line as two lines (or more). I verfied with readLines that an embedded blank in a character field causes a spurious new line to be seen. I am sure this problem has beem seen before - and would appreciate any help in reading
2010 Mar 23
2
Creating pdfs using qplot in qqplot2
I am trying to create plots within a for loop and output them to a pdf. Here is a working example using plot: gg <- data.frame(datadate=1:4, spread=5:8) pdf() for (i in 1:3) { plot(gg$datadate, gg$spread, main=i) } dev.off() I am trying to learn more about ggplot2 so I try a slight modification and it doesn't work. Anyone
2009 Oct 12
0
combining/overlaying boxplot and barplot
Dear all, I would like to visualise when days are rainy or dry in bar/boxplots. Therefore I've tried to combine raingauge data (boxplots) and percentage of raingauges with 0mm measurements (barplot). See attachment mei2004.pdf (if it came through). I've come this far: barplot(dcp0[monthindex], col="gray", border=NA, axes=F) boxplot(t(dcpn[monthindex,]),
2011 Aug 05
0
[LLVMdev] RFC: Exception Handling Rewrite
On Aug 5, 2011, at 10:57 AM, Peter Lawrence wrote: > However it seems that if a landingpad-block has multiple predecessors (often the case, > multiple InvokeInst in the main body of a try-statement all go to the same landingpad- > block), then you cannot move the LandingpadInst in order to break a critical edge unless > you do it for _all_ landingpad-block predecessor edges
2006 Jul 05
10
Google/Netflix Like Tooltips
I need to have a toolip-like object which has dynamic content in it. I plan on using scriptaculous with an ajax call to retrieve the content, but I would like to make the popup/tooltip/balloon text look as nice as possible. Does anyone have any examples or anything useful to create a popup like the ones that Google and Netflix have? I''d like to have one which must be
2011 Aug 05
3
[LLVMdev] RFC: Exception Handling Rewrite
Guys, on second thought... doesn't making the exception registers live from the InvokeInst to the LandingpadInst create problems for critical-edge-splitting ? if a landingpad-edge is critical and needs to be split, won't we be creating and inserting a new BB between the "invoke-block" and the "landingpad-block", and if we do then isn't there the
2006 Jan 23
1
exporting dates into Microsoft SQL Server
I am running R 2.1.1 in a Windows XP environment. I wish to use the sqlSave command to export a dataframe into Microsoft SQL. My dataframe is called temp and has 2 ?columns?, ?monthenddate? and ?value?. Monthenddate is in 'POSIXct', format. (i.e. 'POSIXct', format: chr "1984-01-31" "1984-01-31" "1984-01-31" "1984-01-31" ...). How can I
2001 Dec 07
0
The metadata problem
Maybe this will help, maybe it's fuel on the fire. Who knows. <p>I think we should first of all recognize there's different kinds of metadata; they most of all differ in _what you use it for_. <p>Kind (1) is what the Vorbis comment header is: human readable comments. It's just the same as if you're sitting in a bar and tell a friend "hey, have you heard the new