search for: intantiate

Displaying 2 results from an estimated 2 matches for "intantiate".

Did you mean: instantiate
2011 May 21
1
How to intantiate a list of data.frames?
Hello, I am newbie to R and I want to do this: for(i in 1:6) { ds[i] <- list(df=data.frame(oilDF[,1],oilDF[,i+2]), df2=data.frame(oilDF2[,1],oilDF2[,i+2])) } #oilDF and oilDF2 are 2 data frames with several columns. They have different number of rows #I want to have for example ds[1]$df, ds[1]$df2 with the respective data.frames. #How can I instantiate a list of data.frames pairs
2008 May 28
3
Mocking objects to test Rails Controllers
Hi all, I''m currently considering the use of Mocha to aid in writing my Rails unit/functional tests. I currently have a Rails model which mixes in a series of methods to allow it to talk to an external service. The code is roughly of this form: class Person < ActiveRecord::Base include SMSNotifier def send_notification(message) send_sms(number,message) #