I also noticed that ctx_effect had been declared as an int. This should be a double I think: const double ctx_effect = 0.33;. Have fixed that in the PR.
It compiles now, but when I tried to test running, I got an error (I think a missing file in the pushed branch):
> hivp <- prepare_leapfrog_projp(pjnz)
Error in file(file, "rt") : cannot open the connection
In addition: Warning message:
In file(file, "rt") :
cannot open file 'tests/testdata/spectrum/v6.13/paed_art_dist.csv': No such file or directory
So leaving for you to test :smile:.
In reviewing the code, I noticed a couple of other things interested to discuss:
This uses an alternate constructor posted on Github issue by Kevin Usher (thanks!!): https://github.com/RcppCore/Rcpp/issues/243#issuecomment-73378636
I also noticed that
ctx_effect
had been declared as anint
. This should be a double I think:const double ctx_effect = 0.33;
. Have fixed that in the PR.It compiles now, but when I tried to test running, I got an error (I think a missing file in the pushed branch):
So leaving for you to test :smile:.
In reviewing the code, I noticed a couple of other things interested to discuss:
trans
means.hivnpop1
needs an output.