unable to use functions require DLL from package
On Aug 15, 2014, at 2:56 PM, Charlotte de Vries wrote:
David Winsemius <dwinsemius <at> comcast.net> writes:
On Aug 15, 2014, at 8:06 AM, Charlotte de Vries wrote:
Hey there! I'm having problems with the same code, but I get a different error:
This is apparently yet another example demonstrating why the Posting Guide
suggests that you include the
text of any earlier posting to which you want us to consider. At the
moment I see no posting that has this subject.
Error in .C("spline_coef", method = as.integer(method), n = n, x =
as.double(x), :
"spline_coef" not available for .C() for package "stats"
I'm using R3.1.0 on windows 8 and I've never used R before, so I might
have
made some terrible newby error (I have programmed quite a bit before,
but in C
and Matlab). Thank you! Best,
David Winsemius Alameda, CA, USA
Hi David, Thank you for answering. The original message I replied to was this message (http://comments.gmane.org/gmane.comp.lang.r.general/113245): **********************************************
Well, that explains why I don't have a copy on my machine. It's dated 6 May 18:15 2008
Hi all, I have issues using some basic functions in R such as these ones :
pp.test is not a "basic R function". I get this:
?pp.test
No documentation for ?pp.test? in specified packages and libraries: you could try ???pp.test? You are asked to include the package name for non-base R functions.
pp.test(R) (where is a vector of returns)
Error in .C("R_approx", as.double(x), as.double(y), as.integer(nx), xout =
as.double(xout), :
C symbol name "R_approx" not in DLL for package "base"
boxcox(reg,plotit=T) (where reg is an lm object)
Error in .C("spline_coef", method = as.integer(method), n = as.integer(nx),
:
C symbol name "spline_coef" not in DLL for package "base"
Well I do have the MASS package from which that function was loaded.
I get no error with the example in the help page:
boxcox(Days+1 ~ Eth*Sex*Age*Lrn, data = quine,
lambda = seq(-0.05, 0.45, len = 20), plotit=TRUE)
... and you are not providing a reproducible example that provokes the error, nor are you providing the version numbers of R or MASS.
as I do miss some symbol names. How can I overcome this serious problem ? *********************************** But someone else reported a very similar problem (oddly enough using the same function spline_coef but this time from the package stats rather than base (http://comments.gmane.org/gmane.comp.lang.r.general/115420):
Which was in turn dated: 2 Jun 06:04 2008
************************************ Subject: Missing "spline_coef" DLL and Rob Hyndmans monotonic interpolator Hello R help I have been trying to use Rob Hyndman's monotonically increasing spline function. But like another user or two seem have a problem with a missing DLL (namely "spline_coef"). None of the previous help postings seemed to have any solutions to this problem. As per a Ripley suggestion I have deleted all previous versions of R and reinstalled R 2.7.0 and the problem persists. Thanks Paul. x <- seq(0,4,l=20) y <- sort(rnorm(20)) plot(x,y) lines(spline(x, y, n = 201), col = 2) # Not necessarily monotonic lines(cm.spline(x, y, n = 201), col = 3)
I get no error after: library(demography) # And then running that code. I have an almost up-to-date version of R running on a mac (and at the moment I have way too many packages loaded:
sessionInfo()
R version 3.1.0 Patched (2014-04-21 r65431) Platform: x86_64-apple-darwin10.8.0 (64-bit) locale: [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8 attached base packages: [1] grDevices datasets splines graphics utils stats [7] grid methods base other attached packages: [1] demography_1.17 ftsa_3.9 rainbow_3.2 [4] pcaPP_1.9-49 forecast_5.4 timeDate_3010.98 [7] zoo_1.7-11 XML_3.98-1.1 RCurl_1.95-4.3 [10] bitops_1.0-6 subplex_1.1-4 MASS_7.3-31 [13] cobs_1.2-2 quantreg_5.05 gplots_2.13.0 [16] reshape2_1.2.2 ggplot2_0.9.3.1 multcomp_1.3-1 [19] TH.data_1.0-3 mvtnorm_0.9-9999 data.table_1.9.2 [22] muhaz_1.2.5 downloader_0.3 RJSONIO_1.3-0 [25] plot3D_1.0-1 rms_4.2-0 SparseM_1.03 [28] Hmisc_3.14-4 Formula_1.1-1 survival_2.37-7 [31] sos_1.3-8 brew_1.0-6 lattice_0.20-29 loaded via a namespace (and not attached): [1] caTools_1.16 cluster_1.15.2 colorspace_1.2-4 [4] descr_1.0.3 dichromat_2.0-0 digest_0.6.4 [7] fracdiff_1.4-2 gdata_2.13.3 gtable_0.1.2 [10] gtools_3.4.0 hdrcde_3.1 KernSmooth_2.23-12 [13] ks_1.9.1 labeling_0.2 latticeExtra_0.6-26 [16] Matrix_1.1-3 mgcv_1.7-29 misc3d_0.8-4 [19] munsell_0.4.2 nlme_3.1-117 nnet_7.3-8 [22] parallel_3.1.0 plyr_1.8.1 proto_0.3-10 [25] quadprog_1.5-5 RColorBrewer_1.0-5 Rcpp_0.11.1 [28] rgl_0.93.996 sandwich_2.3-0 scales_0.2.3 [31] stringr_0.6.2 tools_3.1.0 tseries_0.10-32 [34] xtable_1.7-3 So that shows you how to provide some of the needed information (which neither of the postings to which you resonded had done.) PLEASE read the Posting Guide.
Error in .C("spline_coef", method = as.integer(method), n = nx, x = x,
:
C symbol name "spline_coef" not in DLL for package "stats"
Cm.spline code from
http://www-personal.buseco.monash.edu.au/~hyndman/Rlibrary/interpcode.R
**********************************
I hope that helps, thank you :)! I've tried calling spline_coef from both
stats and base, but I get the same error for both packages. I've also tried
the solution suggested to these people, which was to remove any other R
versions on my laptop.
Best,
Lotte
David Winsemius Alameda, CA, USA