Re: [R] data and parameters

2011-01-24 Thread analys...@hotmail.com
> Moritz Grenkehttp://www.360mix.de > > -Ursprüngliche Nachricht- > Von: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] Im > Auftrag von analys...@hotmail.com > Gesendet: Freitag, 21. Januar 2011 03:02 > An: r-h...@r-project.org > Betreff: [R] data

Re: [R] data and parameters

2011-01-21 Thread jim holtman
forgot the control parameters: > sqldf(" + select m.*, c.control_params + from master m, control c + where m.clientId = c.clientID + and m.date between c.mindate and c.maxdate + ") clientId date value control_params 12 1002 10002 1 2

Re: [R] data and parameters

2011-01-21 Thread jim holtman
try 'sqldf' > master=as.data.frame(list(clientId=c(1:4,2), date=1001:1005, + value=10001:10005)) > control=as.data.frame(list(clientId=c(2,3), mindate=c(100,1005), + maxdate=c(1005,1005), control.params=c(1,2))) > master clientId date value 11 1001 10001 22 1002 10002 33

Re: [R] data and parameters

2011-01-21 Thread Moritz Grenke
3:02 An: r-help@r-project.org Betreff: [R] 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 cont

[R] data and parameters

2011-01-20 Thread analys...@hotmail.com
(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 ID