Re: [R-pkg-devel] data and load version 3
On 6/30/20 11:48 AM, Göran Broström wrote: On 2020-06-30 01:07, Jeff Newmiller wrote: Your choice. Do you want to support people using older versions of R, or not? Is that all? No point at all with version 3 in packages? Why was it introduced? I have seen an argument for version 2: "... needed ... to support name spaces", but version 3 ... Format 3 supports efficient serialization of ALTREP objects, that is why it was introduced. It also saves the session native encoding and converts string on de-serialization when running in different native encoding. Documented also in R 3.5 NEWS, in R Internals. Tomas Göran On June 29, 2020 1:55:02 PM PDT, "Göran Broström" wrote: I added two data sets (.rda) to my package eha, but when I build the new version I get: WARNING: Added dependency on R >= 3.5.0 because serialized objects in serialize/load version 3 cannot be read in older versions of R. File(s) containing such objects: ‘eha/data/swedeaths.rda’ ‘eha/data/swepop.rda’ In DESCRIPTION I have 'Depends: R (>= 3.0.0)' After googling for a while (found nothing relevant in 'WRE'), I understand that I have two options: (i) Change 'Depends' in DESCRIPTION as suggested, and (ii) using save with 'version = 2' for the new files. And, if I am recommended to choose (i), should I recreate the old data files with 'version = 3'? My guess is go for (i) and version = 3 for all data files, but I feel that I need advise. Thanks, Göran __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] data and load version 3
On 2020-06-30 11:58, Ivan Krylov wrote: On Tue, 30 Jun 2020 11:48:29 +0200 Göran Broström wrote: No point at all with version 3 in packages? Format version 3 [1] introduces support for ALTREP objects [2]. Examples of where ALTREP might be useful include really long integer vectors, like 1:1e10. Thanks, no need for that in the actual data files, so I'll convert them to version 2. Göran __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] data and load version 3
On Tue, 30 Jun 2020 11:48:29 +0200 Göran Broström wrote: > No point at all with version 3 in packages? Format version 3 [1] introduces support for ALTREP objects [2]. Examples of where ALTREP might be useful include really long integer vectors, like 1:1e10. -- Best regards, Ivan [1] https://developer.r-project.org/blosxom.cgi/R-3-5-branch/NEWS/2018/04/11#n2018-04-11 [2] https://svn.r-project.org/R/branches/ALTREP/ALTREP.html __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] data and load version 3
On 2020-06-30 01:07, Jeff Newmiller wrote: Your choice. Do you want to support people using older versions of R, or not? Is that all? No point at all with version 3 in packages? Why was it introduced? I have seen an argument for version 2: "... needed ... to support name spaces", but version 3 ... Göran On June 29, 2020 1:55:02 PM PDT, "Göran Broström" wrote: I added two data sets (.rda) to my package eha, but when I build the new version I get: WARNING: Added dependency on R >= 3.5.0 because serialized objects in serialize/load version 3 cannot be read in older versions of R. File(s) containing such objects: ‘eha/data/swedeaths.rda’ ‘eha/data/swepop.rda’ In DESCRIPTION I have 'Depends: R (>= 3.0.0)' After googling for a while (found nothing relevant in 'WRE'), I understand that I have two options: (i) Change 'Depends' in DESCRIPTION as suggested, and (ii) using save with 'version = 2' for the new files. And, if I am recommended to choose (i), should I recreate the old data files with 'version = 3'? My guess is go for (i) and version = 3 for all data files, but I feel that I need advise. Thanks, Göran __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] data and load version 3
On Mon, 29 Jun 2020 22:55:02 +0200 Göran Broström wrote: > After googling for a while (found nothing relevant in 'WRE'), I > understand that I have two options: (i) Change 'Depends' in > DESCRIPTION as suggested, and (ii) using save with 'version = 2' for > the new files. One of the steps performed by default during R CMD build is tools::resaveRdaFiles(), which passes NULL as version= argument to save(). Around R (not sure about this) 3.6.0 version=NULL was changed to mean version=3, so if you want to preserve compatibility with R < 3.5.0, you may need to run tools::resaveRdaFiles(..., version = 2) before running R CMD build --no-resave-data. -- Best regards, Ivan __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] data and load version 3
Your choice. Do you want to support people using older versions of R, or not? On June 29, 2020 1:55:02 PM PDT, "Göran Broström" wrote: >I added two data sets (.rda) to my package eha, but when I build the >new >version I get: > > WARNING: Added dependency on R >= 3.5.0 because serialized objects in >serialize/load version 3 cannot be read in older versions of R. >File(s) >containing such objects: ‘eha/data/swedeaths.rda’ >‘eha/data/swepop.rda’ > >In DESCRIPTION I have 'Depends: R (>= 3.0.0)' > >After googling for a while (found nothing relevant in 'WRE'), I >understand that I have two options: (i) Change 'Depends' in DESCRIPTION > >as suggested, and (ii) using save with 'version = 2' for the new files. > >And, if I am recommended to choose (i), should I recreate the old data >files with 'version = 3'? > >My guess is go for (i) and version = 3 for all data files, but I feel >that I need advise. > >Thanks, Göran > >__ >R-package-devel@r-project.org mailing list >https://stat.ethz.ch/mailman/listinfo/r-package-devel -- Sent from my phone. Please excuse my brevity. __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
Re: [R-pkg-devel] data and load version 3
On 29.06.2020 22:55, Göran Broström wrote: I added two data sets (.rda) to my package eha, but when I build the new version I get: WARNING: Added dependency on R >= 3.5.0 because serialized objects in serialize/load version 3 cannot be read in older versions of R. File(s) containing such objects: ‘eha/data/swedeaths.rda’ ‘eha/data/swepop.rda’ In DESCRIPTION I have 'Depends: R (>= 3.0.0)' After googling for a while (found nothing relevant in 'WRE'), I understand that I have two options: (i) Change 'Depends' in DESCRIPTION as suggested, and (ii) using save with 'version = 2' for the new files. And, if I am recommended to choose (i), should I recreate the old data files with 'version = 3'? My guess is go for (i) and version = 3 for all data files, but I feel that I need advise. You may use version 3 for all, but you can also have a mix and only use vesion 3 for the new files. Best, Uwe Ligges Thanks, Göran __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
[R-pkg-devel] data and load version 3
I added two data sets (.rda) to my package eha, but when I build the new version I get: WARNING: Added dependency on R >= 3.5.0 because serialized objects in serialize/load version 3 cannot be read in older versions of R. File(s) containing such objects: ‘eha/data/swedeaths.rda’ ‘eha/data/swepop.rda’ In DESCRIPTION I have 'Depends: R (>= 3.0.0)' After googling for a while (found nothing relevant in 'WRE'), I understand that I have two options: (i) Change 'Depends' in DESCRIPTION as suggested, and (ii) using save with 'version = 2' for the new files. And, if I am recommended to choose (i), should I recreate the old data files with 'version = 3'? My guess is go for (i) and version = 3 for all data files, but I feel that I need advise. Thanks, Göran __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel