malucalle/selbal

Install error

Opened this issue · 4 comments

Hello, I get wrong with installation of "selbal" this time in jupyter notebook. The error is following:

  • installing source package ‘selbal’ ...
    ** using staged installation
    ** R
    Error in parse(outFile) :
    /private/var/folders/41/8b97vwt914n5ldqg_5hldhq80000gn/T/Rtmpa38tRQ/R.INSTALLa42c23db5423/selbal/R/Selbal_Functions.R:841:24: unexpected ','
    840: # Compute the balances for the training data set
    841: BAL <- (x.train,
    ^
    ERROR: unable to collate and parse R files for package ‘selbal’

Is any bugs in the codes of Selbal_Functions.R?

And also:

  • installing source package ‘selbal’ ...
    ** using staged installation
    ** R
    Error in parse(outFile) :
    /private/var/folders/41/8b97vwt914n5ldqg_5hldhq80000gn/T/RtmpCC6NQw/remotesae127d73abd6/selbal-master/R/Selbal_Functions.R:990:31: unexpected ','
    989: # Define NUM and DEN according to opt.M
    990: suppressMessages(BAL <- (x,
    ^

who has the old version of the right codes, would you like to share with me?

I'm not sure what happened but I checked the original code that raise error.

        BAL <- (x.train, y.train, th.imp = 0, covar = covar.train,
                          logit.acc, logt=F, maxV = maxV)

Is that a valid form for R?

I recently faced some challenges while trying to install the latest version of selbal too. But I successfully installed a previous stable version by using the following command:

devtools::install_github(repo = "malucalle/selbal@4b4d3804bfe4c6948e4bc96f7d19043f60337b42")

The specified SHA (4b4d3804bfe4c6948e4bc96f7d19043f60337b42) corresponds to the commit from September 3, 2021 and this approach works. Sharing this in case others are facing similar difficulties with the latest version.

Hi!

Thanks for letting us know about the error.
We just updated the code, it seems to work again.

Let us know if it works for you.

Thank you very much again