similar to: learning S4

Displaying 20 results from an estimated 2000 matches similar to: "learning S4"

2007 Dec 16
2
clean programming
Hello the list, I am trying to write a "cleanProgramming" function to test the procedure I use. For example, I want to be sure that I am not using globals variables. The function "findGlobals" detect that. To list the globals used in function "fun", the syntax is : "findGlobals(fun,FALSE)$variable" My problem is that I want to use it in a function,
2008 Feb 29
1
inheritence in S4
Hi the list I define a class A (slot a and b), a class C (slot c and d) and a class E that inherit from A and B. I define print(A) and print(B). For print(C), I would like to use both of them, but I do not see how... Thanks for your help... Christophe ---------------------------------------------------------------- Ce message a ete envoye par IMP, grace a l'Universite Paris 10 Nanterre
2008 Apr 13
1
R 2.7 package.skeleton
Hi the devel list I am testing package.skeleton in R 2.7 (download today). I get an error that I do not understand. I guess it is not an error from my code since I have no probleme when I source it. So is it a error in package.skeleton? Here is my code : --- 8< ------ File essai.r ------------- setClass( Class="ClusterizLongData", representation=representation(
2014 Mar 19
1
Memcheck: Invalid read of size 4
Hi the list, One of my package has a memory issue that I do not manage to understand. The Memtest notes is here: <http://www.stats.ox.ac.uk/pub/bdr/memtests/valgrind/kml-Ex.Rout> Here is the message that I get from Memtest --- 8< ---------------- ~ Fast KmL ~ ==27283== Invalid read of size 4 ==27283== at 0x10C5DF28: kml1 (kml.c:183) ... ==27283== by 0x10C5DE4F: kml1 (kml.c:151)
2008 Apr 13
1
getGraphicsEvent plotting two graph
Hi the list, I need to use getGraphicsEvent to plot two graph. On the following toy example: - the function b is ploting two graph depending on a parameter - the function a is calling b according to some user answers. It is suppose to call b until the user press Return, but it does not. b <- function(x){ dev.off(2);dev.off(3) windows();windows(3,3,xpos=0) dev.set(2);plot(1:x)
2008 Aug 07
1
package.skeleton does invalide regular name, bis... (PR#12020)
Hi the list, I guess I find an other bug (the first one is at the end off this mail) in package.skeleton. It occurs when we give as code_file some file that are not in the current directories. If we give a single file to code_file (like code_file=3D"riri/fifi.R"), it does not reconize fifi.R as a regular name and change it to riri/zfifi.R If we give several file to code_file (like
2008 Jan 28
1
Integer vs numeric
Hi the list. I do not understand the philosophy behind numeric and integer. - 1 is numeric (which I find surprising) - 2 is numeric. - 1:2 is integer. Why is that ? Christophe
2008 Feb 23
1
Set without argument
Hi the list, I am defining S4 objet. Is it possbile to define a method that change the slot of an object without using <- ? My object contain a numeric and a matrix. At some point, I would like to impute the missing value in the matrix. So I would like to use something like : ----------------- setClass("MyObj",representation(time="numeric",traj="matrix")) a
2007 Jul 08
2
longitudinal data
Hello all, I want to analyze data that looks like this: Id var1 var2 var3.. 1 0 1 0 1 0 1 1 2 2 2 2 Not all id's have the same no. of observations. At the first stage I want to count how many people in the survey, how many have 1 in var1, etc. How do I do that? Thank you, Sigalit. [[alternative HTML version deleted]]
2008 Oct 13
1
Gower distance between a individual and a population
Hi the list, I need to compute Gower distance between a specific individual and all the other individual. The function DAISY from package cluster compute all the pairwise dissimilarities of a population. If the population is N individuals, that is arround N^2 distances to compute. I need to compute the distance between a specific individual and all the other individual, that is only N
2009 Jun 09
3
"R CMD check" does not find a mistake
Hi the list, I build a package. They was a mistake in it, but R CMD check did not find it. Is that normal ? Here is what Kurt gets (which is right, I did this mistake): --- 8< ---------------- * checking for code/documentation mismatches ... WARNING S4 class codoc mismatches from documentation object 'LongData-class': Slots for class 'LongData' Code: id other time traj
2008 Jan 15
1
bug in mmlcr ? (PR#10576)
Hi the list. Is there a bug in mmlcr package ? The following code does not compile: mmlcrTest <- function(dataW){ dataL <- reshape(dataW,idvar="id",timevar="T",varying=list("T0","T1","T2"),direction="long",v.names="score") resultR <- mmlcr(outer= ~ 1 | id, components = list(list(formula =
2012 Jun 09
2
Help with permutation function from Turner et al. 2010 (Ecology)
Hello, I'm using R code that includes a residual permutation that was written as a supplement to the paper: Turner et al. 2010. A general hypothesis-testing framework for stable isotopes ratios in ecological studies. Ecology 91:2227-2233. The supplemental code is available at: http://www.esapubs.org/archive/ecol/E091/157/suppl-1.htm When I execute the function, no warnings are given
2009 Sep 09
1
Package that does not work until I re write the exactly the same code
Hi the list, I am writing a package in S4 and I do not manage to understand a bug. The "R CMD check" and the "R CMD build" both work. Here is links to the package (not on CRAN yet for the raison that I explain bellow): http://christophe.genolini.free.fr/aTelecharger/kml_0.5.zip http://christophe.genolini.free.fr/aTelecharger/kml_0.5.tar.gz Then I install the package and I
2002 Nov 25
2
Pspline smoothing
Dear all, I'm trying to use the Pspline add-on package to fit a quintic spline (norder =3), but I keep running into a Singularity error. > traj.spl <- smooth.Pspline(time, x, norder=3 ) Error in smooth.Pspline(time, x, norder = 3) : Singularity error in solving equations > Playing around with the other parameters produces an "unused arguments" error: > traj.spl
2003 Aug 24
2
setClass question
I would like to add a class to the SparseM package. I have a class "matrix.csr" that describes a matrix in compressed sparse row format, now I would like a class matrix.diag.csr that describes such objects when they happen to be diagonal. The idea is that matrix.diag.csr objects should behave (later in life) exactly like matrix.csr objects, the distinction is only needed in order to
2013 Jan 14
4
How to open grib file in R?
I have this https://echange-fichiers.inra.fr/get?k=6TdTdezNeZwAqJtpwVm grib file which is a regular lat-lon 0.25x0.25 degrees and contains 4 fields . I tried to open it using : grib <- readGDAL("C:\\Users\\aalyaari\\Desktop\\Vol_025_H14_2010060700.grib") but I got this error: C:\Users\aalyaari\Desktop\Vol_025_H14_2010060700.grib has GDAL driver GRIB and has 721 rows and
2014 Sep 04
1
R CMD check --as-cran does not show all error messages.
Hello, That is my first post here and I'd like to thanks everybody in advance. I am writing a package with some R functions and try to submit it to CRAN. After build and check the package a number of times, I am struggling with the fact that the CRAN people responsible for checking packages are replying me with some mistakes that I just do NOT get when I do the check in my computer. With the
2012 Nov 19
2
Is it possible to be sponsored by R?
Hi the list, I am a member of the organizing comity of the French Statistics Association (SFdS)'s conference. We are looking for sponsors. Some software (SAS, RITME, ...) are represented. Do you know if there is any possibility to be sponsored by R (or by an association close to R)? Do you think I can ask to the R fondation? Sincerely Christophe -- Christophe Genolini MaƮtre de
2015 May 26
0
Compatibility issue between lme4 and kml (operateur "[")
Hi all, There is a compatibility issue between the package 'lme4' and my package 'kml'. I define the "[" operator. It works just fine in my package (1). If I try to use the lme4 package, then it does no longer work (2). Moreover, it has some kind of strange behavior (3). Do you know what is wrong? Any idea of how I can correct that? Thanks for your help Christophe ---