klausspanderen / rhestonslv Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v2.0
License: GNU General Public License v2.0
Hello and thanks for this nice package
I tried to build RHestonSLV for R-4.0.5 (thereby also relying mostly on the new Rtools40 toolchain) but then ran into two errors
OS:Windows 10
R.version: R-4.0.5 using Rtools 4 w MinGW 64-Bit for building
boost 1.77.0
QuantLib 1.23
localvolrndcalculator
moving from experimtental/finitedifferences
to methods/finitedifferences/utilities
- for which I could offer a pull request (if you would like to include it?)BUT on the second one I am stuck, since I am not familiar enough with the Transformations between objects being poossible and/or going on in QuantLib or your code, which maybe (also) got "broken" by some updates in QL [or boost]?
2. This 2nd error during binary package building looks like:
hestonslvmodule.cpp:458:5: error: cannot convert 'const QuantLib::FdmSquareRootFwdOp::TransformationType' to 'const QuantLib::FdmHestonGreensFct::Algorithm' in initialization
hestonslvmodule.cpp:458:5: error: cannot convert 'const QuantLib::FdmSchemeDesc' to 'const QuantLib::FdmSquareRootFwdOp::TransformationType' in initialization
hestonslvmodule.cpp:458:5: error: could not convert '<brace-enclosed initializer list>()' from '<brace-enclosed initializer list>' to 'const QuantLib::FdmSchemeDesc'
make: *** [C:/PROGRA~1/R/R-40~1.5/etc/i386/Makeconf:229: hestonslvmodule.o] Error 1
ERROR: compilation failed for package 'RHestonSLV'
Any hints where I should potentially adapt source or look further into detail ... *warning you -> I am a bit / quite rusty on my C++
Thanks
GWD
The build now against R-4.0.5 on Ubuntu 20.04 (after commit 8a169a3) runs smoothly
But after starting R-4.0.5 and loading library below behavior can be observed:
❯ library(RHestonSLV)
Error: package or namespace load failed for ‘RHestonSLV’:
.onLoad failed in loadNamespace() for 'RHestonSLV', details:
call: getQuantLibVersion()
error: could not find function "getQuantLibVersion"
I have also noticed that in files Makevars
and Makvars.in
PKG_LIBS=$(shell "Rscript" -e "Rcpp:::LdFlags()") -lQuantLib -lrt
is used in which Rcpp:::LdFlags()
is a deprecated Rcpp function (as of Rel. 0.12.19) and returns an empty string. It seems to me that somehow the build package is not picking up the Rcpp exported getQuantLibVersion()
and my guess is that the PKG_LIBS do not get linked correctly?
By commenting out the whole getQuantLibVersion()
function part in zzz.R
the library manages to load, but currently I have not succeeded to produce results with any of the demo code.
And one final minor detail (more like an inconsistency nothing really serious) I noted in zzz.R
qlver <- getQuantLibVersion()
if (compareVersion(qlver, "1.12") < 0) {
packageStartupMessage("QuantLib version ", qlver, " detected which is older than 1.8.")
...
there is a comparison against "1.12"
and the message following it "still" mentions version 1.8
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.