search for: rfunction

Displaying 15 results from an estimated 15 matches for "rfunction".

Did you mean: function
2007 Oct 09
3
How to create something between a script and a package
...feel that this is not exactly what I want and I'm kinda lost regarding what alternatives are available. What I want could be summarized as this: - A plain text file (eg: myfunctions.R) - Can be located in other folders besides the default (easier to synchronize using subversion). Eg: myproject/rfunctions/myfunctions.R - Can be accessed from the R console (without having to load a specific workspace). Is there any solution that can provide this? Any suggestions would be greatly appreciated, Thanks, Sergio
2013 Aug 28
1
Error when using buildVignettes()
...#if }#xpsQAReport #------------------------------------------------------------------------------# The file "QC.begin.Rnw" is as follows: \documentclass{article} \textwidth=6.2in \textheight=8.5in %\parskip=.3cm \oddsidemargin=.1in \evensidemargin=.1in \headheight=-.3in \newcommand{\Rfunction}[1]{{\texttt{#1}}} \newcommand{\Rmethod}[1]{{\texttt{#1}}} \newcommand{\Rcode}[1]{{\texttt{#1}}} \newcommand{\Robject}[1]{{\texttt{#1}}} \newcommand{\Rpackage}[1]{{\textsf{#1}}} \newcommand{\Rclass}[1]{{\textit{#1}}} \newcommand{\Cclass}[1]{{\textit{#1}}} \newcommand{\Rexten}[1]{{\textit{#1}}} \new...
2009 Feb 13
1
Write and Load functions from an external file
...z.ch/pipermail/r-help/2007-October/142938.html You can save one or more functions and datasets to a file (see ?save) then on starting another session attach that file (see ?attach). The process is like:--- foo <- function(x) mean(as.numeric(x), trim = 0.3) save(foo, file = "myproject/rfunctions/saved.rda") then, when starting a new session, use attach("myproject/rfunctions/saved.rda") The .rda extension on the filename is commonly used for saved R data sets but you can also have function definitions in a saved file. Are these the only ways,and the best ways,to d...
2013 Jun 07
0
[Rcpp-devel] Setting the R random seed from Rcpp
...; > > Dear Rcpp experts, > > > > I would like to be able to store the R random seed from a Rcpp > > function and then reset it. In other words I would like to replicate > > the following code in Rcpp: > > > > savedSeed <- .Random.seed > > x <- Rfunction(parameters1); > > > > .Random.seed <- savedSeed > > x1 <- Rfunction(parameters2); > > > > where Rfunction simulates some random numbers and uses them > > but with different parameter values. > > Is it possible to do something similar in Rcpp? > &gt...
2015 Apr 30
2
R CMD check and missing imports from base packages
...ed, Apr 29, 2015 at 8:12 PM, Paul Gilbert <pgilbert902 at gmail.com> wrote: > > As I recall, several packages mask the simulate generic in stats, if you > are looking for examples. > FWIW, here is a list of base* functions masked** by CRAN packages: https://github.com/gaborcsardi/rfunctions/blob/master/rfunctions.md Look at the long table in the end. simulate indeed comes up 16 times. (But read ** below.) * This only includes functions in base packages that are attached by default. ** The CRAN function names were taken from the manual page aliases, so a couple of them are not really...
2000 Mar 07
0
AW: R-crash using cut-and-paste (PR#472)
...quot;F:/DIDITEX/compstatr/ss00/r2latex/"){ tf_paste(c(dir,form,".r2l"),collapse="") cat(c("Reading ",tf,".\n"),collapse="") ss_scan(file=tf,what="",sep="\n",quiet=TRUE) sss_ss a_(1:length(sss))[ss==as.vector("\\end{RFunction}")] sss_sss[1:a-1] b_(1:length(sss))[ss==as.vector("\\begin{RFunction}")] collect.expressions_function(ss){ ss_ss[grep("%",ss)] ss_paste(ss,collapse="") ss_substring(ss,1:nchar(ss),1:nchar(ss)) ss_as.vector(ss[!((ss=="%")|(ss==" "))])...
2009 Nov 11
1
fisher.test negative value error
...test'](m) return s * Here the value of a=0,b=1,c=0 and d=1. so the matrix m should be like this [,1] [,2] [1,] 0 0 [2,] 1 1 But I am getting an error like this *File "/usr/lib64/python2.6/site-packages/rpy2/robjects/__init__.py", line 422, in __call__ res = super(RFunction, self).__call__(*new_args, **new_kwargs) rinterface.RRuntimeError: Error in function (x, y = NULL, workspace = 2e+05, hybrid = FALSE, control = list(), : all entries of 'x' must be nonnegative and finite* clearly every element of matrix m is +ve but I don't know why I am getting thi...
2015 Apr 30
0
R CMD check and missing imports from base packages
...rt902 at gmail.com> wrote: >> >> As I recall, several packages mask the simulate generic in stats, if you >> are looking for examples. >> > FWIW, here is a list of base* functions masked** by CRAN packages: > https://github.com/gaborcsardi/rfunctions/blob/master/rfunctions.md > Look at the long table in the end. simulate indeed comes up 16 times. (But > read ** below.) > * This only includes functions in base packages that are attached by > default. > ** The CRAN function names were taken from the manual pag...
2004 May 04
2
Epidemiology Tools
Hi all, Please help on this. We will be teaching epidemiology using opensource software. What are R built-in functions or functions in available packages that are capable of doing these: a) Logistic regression (glm?) b) Conditional logistic regression c) Logistic regression with random effects d) Beta-binomial regression e) Poisson regression f) Weibull regression (eha?) g) Exponential
2008 Apr 29
2
Calling R from C - part way there but need a push!
...good news is that I can now call _some_ R from C, specifically the R functions which have C header files. However it isn't clear to me how to call R functions that are written in R. I imagine that there is a standard C function of the form Call_r_from_C("package name", "Rfunction name as a string", arg1, arg2, ...); where arg1 etc are standardised ways of representing R data structures in C. However I haven't been able to find such a function prototype in the R include/*.h files. See footnote (1). Can you point me in the right direction please? Is ther...
2015 Apr 29
2
R CMD check and missing imports from base packages
> And in general a developer would avoid masking a function > in a base package, so as not to require the user to distinguish > between stats::density() and igraph::density(). Maybe the > example is not meant literally. The 'filter' function in the popular 'dplyr' package masks the one that has been in the stats package forever, and they have nothing in common, so that
2003 Oct 27
0
AW: Query: IRR Confidence Intervals
Hi Cristian, I don't know about a R routine for exact CIs, but I found a function called "ageadjust" using a gamma distribution approximation some time ago -take a look at http://medepi.org/epitools/rfunctions/index.html. That Webpage seems a bit outdated now, but the calculations given in the ageadjust functions should still work, I think. Maybe this helps; regards Heinrich. > -----Urspr?ngliche Nachricht----- > Von: cristian at biometria.univr.it [mailto:cristian at biometria.univr.it] >...
2013 May 01
1
rpy2 postgres qgis problem
? stato filtrato un testo allegato il cui set di caratteri non era indicato... Nome: non disponibile URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20130501/294047df/attachment.pl>
2001 Sep 27
2
Getting your stuff organized in R
...uot; "no.na.mat" "no.rep.mat" [10] "parcelas.lda" "parcelas.liss.func" "reclas" [13] "rescale" "utm2lincol" You can use lsf() to save your functions to a file: > save(list=lsf(), file="Rfunctions.rda") 9. Actually, it's more usual to save functions in text format, which you can do with: > dump(list=lsf(),file="testdump.R") But you cannot use either load() or attach() with files created by dump(). Instead, you must use source() > source("testdump.R")...
2006 Oct 24
4
How to start R with a file loaded?
Hi! I've made great progress in my R programming, but I am again stuck on a beginner's problem. I would like to start R with a command line that loads a file, and if possible, executes a function. Can anyone give me an example of how to do this? For example, in lisp, I would say: $ lisp -load toto.lisp -eval '(do-something $PORT)' to load the file "toto.lisp", then