0

I used the package "ref" for creating and using references to objects such as data frames (see sample code part below). That worked really good. But now I switched over to the new R version and when trying to install the package there is an error saying this package is not available for R version 3.5.0.

Is there any other package or function to achieve referencing? Or is there a workaround for usage of the "ref" package under 3.5.0?

...
for (sOneDfIntervResultName in listDfIntervResultNames) {

   #add new row if not existant
   dfRef <- ref(sOneDfIntervResultName)
   deref(dfRef)[nrow(deref(dfRef))+1, ] <- NA

   #write start and end interval datetime
   deref(dfRef)$Interv_StartDatetimeUTC[nrow(deref(dfRef))] <- startIntervalDateTime
   deref(dfRef)$Interv_EndDatetimeUTC[nrow(deref(dfRef))] <- endIntervalDateTime
}
...
Juppes
  • 169
  • 9
  • 3
    Please read the info about [how to ask a good question](https://stackoverflow.com/help/how-to-ask) and how to give a [reproducible example](https://stackoverflow.com/questions/5963269). This will make it much easier for others to help you. – Ralf Stubner Jun 21 '18 at 13:01
  • Thanks for this helpful comment. I did not intend to give a reproducible example but just a excerpt of the code to help understand my question. – Juppes Jun 21 '18 at 13:30
  • 1
    Have a look at the `data.table` package that manipulates data frames by reference – Aurèle Jun 21 '18 at 13:35
  • Thank you, I will have a closer look to that package. – Juppes Jun 21 '18 at 14:47

0 Answers0