volesti icon indicating copy to clipboard operation
volesti copied to clipboard

R tutorial in the documentation is not updated.

Open keithwind opened this issue 9 months ago • 4 comments
trafficstars

On the R tutorial website, the function name used everywhere is GenCube, whereas the actual function name in the R library is gen_cube. Is this intentional? If not can I open a PR to fix it?

Image

Trying GenCube vs gen_cube in the R terminal. Image

keithwind avatar Feb 12 '25 11:02 keithwind

There are multiple other errors in other functions. Is the documentation not updated? I am willing to open a PR to fix all the issues with the tutorial examples.

keithwind avatar Feb 12 '25 11:02 keithwind

Indeed the tutorial in the documentation refers to an old version of the CRAN package. You are more than welcome to fix/update it to refer to the current version on CRAN i.e. 1.1.2. It will also be useful to add a reference in tutorial to which version of CRAN it refers.

NOTE: You can use this tutorial but be careful as it refers to the current development branch of Rvolestihttps://github.com/GeomScale/Rvolesti) which is 1.2.0 so there are some differences (e.g. some now functions not appear in 1.1.2).

vfisikop avatar Feb 13 '25 08:02 vfisikop

library(volesti)
P <- fileToMatrix('data/birk10.ine')

Here we are using the function fileToMatrix which is not present in the current version of volesti. The tutorial you shared uses the function gen_birkhoff which is also not available in the current version. The function gen_birkhoff is small enough that the code for it can be directly added in the documentation. Should I do that or is there any other way to fix this?

keithwind avatar Feb 17 '25 16:02 keithwind

Indeed, fileToMatrix does not appear in the current CRAN version and the gen_birkhoff only appears in the development version. Ways to fix:

  1. add the implementation of gen_birkhoff in tutorial
  2. remove Birkhoff example
  3. create birhoff polytope using Hpolytope class
  4. upgrade the tutorial to use the development version and use gen_birkhoff

I propose to go for 4 and the whole tutorial will refer to development version 1.2.0 which will eventually replace the current CRAN version.

vissarion avatar Feb 18 '25 09:02 vissarion