search for: kmat

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

Did you mean: kmap
2011 Feb 04
1
GWAF package: lme.batch.imputed(): object 'kmat' not found
...v', phen='phen1', covar=c('covar1','covar2'), kinmat='imputed_fhs.kinship.RData', outfile='imputed.FHS.IBC.GWAF.LME.output.0.txt' )) Gives the error messages: Error in coxme.varcheck(ncluster, varlist, n, gvars, groups, sparse, rescale, : object 'kmat' not found Error in lme.cov.out$theta : $ operator is invalid for atomic vectors Might anyone know why? Thank you for your time! Jim --------------------------------------------------- > R.Version() $platform [1] "x86_64-apple-darwin9.6.0" $arch [1] "x86_64" $os [1]...
2011 Apr 15
1
no solution yet, please help: extract p-value from mixed model in kinship package
...rep(13, 10), rep(15, 10), rep(17, 10), rep(19, 10), rep(21, 10)) momid <- c(rep(0, 5), rep(2, 5), rep(4, 5), rep(6, 5), rep(8, 10), rep(10, 10), rep(12, 10), rep(14, 10), rep(16, 10), rep(18, 10), rep(20, 10), rep(22, 10) ) ped <- data.frame(id, dadid, momid) # *****************************kmatrix************************************** > cfam <- makefamid(ped$id,ped$momid, ped$dadid) > > kmat <- makekinship(cfam, ped$id, ped$momid, ped$dadid) > > #*****************************************x and y variables ********************* > set.seed(3456) > > dat <-...
2012 Nov 24
1
Bootstrap lmekin model
...stimate heritability. I want to estimate the confidence interval of the variance coefficient and so I should use a bootstrap simulation. The pedigree file has 1386 subjects so I create a kinship matrix [1386*1386].This is the code of R I use: kfit2 <- lmekin(IT~1+AGE +(1|ID), dati1, varlist=list(kmat))kfit2kfit2$vcoef library(boot) var <- function(formula,data,indices,varlist) { d <- data[indices,] # allows boot to select sample kfit2 <- lmekin(formula, data=d, varlist=list(kmat)) return(kfit2$vcoef)} # bootstrapping with 1000 replications results <- boot(data=dati1, statistic...
2011 Jul 15
1
Confusing inheritance problem
I have library in development with a function that works when called from the top level, but fails under R CMD check. The paricular line of failure is rsum <- rowSums(kmat>0) where kmat is a dsCMatrix object. I'm currently stumped and looking for some ideas. I've created a stripped down library "ktest" that has only 3 functions: pedigree.R to create a pedigree or pedigreeList object, kinship.R with "kinship" methods for the t...
2020 Jan 13
5
as-cran issue
...nes generate an error in R CMD check --as-cran? for coxme.? But there is no error without as-cran nor is there one when I run the code in a terminal window. ismat <- function(x)? inherits(x, "matrix") || inherits(x, "bdsmatrix") || inherits(x, "Matrix") if (ismat(kmat)? ) .... (The second line is repeated multiple times for multiple arguments.? The ismat function is defined simply to save typing.) The check log contains multiple instances of the lines below: < Warning message: < In if (ismat(kmat)) { : <?? the condition has length > 1 and only th...
2020 Jan 13
2
as-cran issue
...the file src/library/tools/R/check.R in the R sources, and grep for > as_cran which is the internal variable controlled by the --as-cran option > > [...] > > | The check log contains multiple instances of the lines below: > | > | < Warning message: > | < In if (ismat(kmat)) { : > | <?? the condition has length > 1 and only the first element will be used > | > | I don't see how the error could arise, but if I know what as-cran is doing perhaps I can > | replicate it. > > This was widely discussed on this list and should also be in the NEW...
2011 Apr 14
0
extract p-value from mixed model in kinship package
...10), rep(17, 10), rep(19, 10), rep(21, 10)) momid <- c(rep(0, 5), rep(2, 5), rep(4, 5), rep(6, 5), rep(8, 10), rep(10, 10), rep(12, 10), rep(14, 10), rep(16, 10), rep(18, 10), rep(20, 10), rep(22, 10) ) ped <- data.frame(id, dadid, momid) cfam <- makefamid(ped$id,ped$momid, ped$dadid) kmat <- makekinship(cfam, ped$id, ped$momid, ped$dadid) set.seed(3456) SNPdata <- c(1:1000) dat <- sample(c(-1,0,1), 10000, replace = TRUE) snpmat<- data.frame(matrix(dat, ncol = 100)) names(snpmat) <- c(paste ("VR",1:100, sep='' )) yvar <- rnorm(100, 30, 5) my...
2020 Jan 13
2
as-cran issue ==> set _R_CHECK_LENGTH_1_* settings!
...ch is the internal variable controlled by the --as-cran option >>> >>> [...] >>> >>> | The check log contains multiple instances of the lines below: >>> | >>> | < Warning message: >>> | < In if (ismat(kmat)) { : >>> | <?? the condition has length > 1 and only the first element will be >>> used >>> | >>> | I don't see how the error could arise, but if I know what as-cran is >>> doing perhaps I can >>> | replicate i...
2020 Jan 13
0
as-cran issue
...e) what options as-cran turns on? See the file src/library/tools/R/check.R in the R sources, and grep for as_cran which is the internal variable controlled by the --as-cran option [...] | The check log contains multiple instances of the lines below: | | < Warning message: | < In if (ismat(kmat)) { : | <?? the condition has length > 1 and only the first element will be used | | I don't see how the error could arise, but if I know what as-cran is doing perhaps I can | replicate it. This was widely discussed on this list and should also be in the NEWS file. The change is about...
2020 Jan 13
0
as-cran issue
...heck.R in the R sources, and grep for >> as_cran which is the internal variable controlled by the --as-cran option >> >> [...] >> >> | The check log contains multiple instances of the lines below: >> | >> | < Warning message: >> | < In if (ismat(kmat)) { : >> | <?? the condition has length > 1 and only the first element will be >> used >> | >> | I don't see how the error could arise, but if I know what as-cran is >> doing perhaps I can >> | replicate it. >> >> This was widely discussed o...
2020 Jan 13
0
as-cran issue
...n R CMD check --as-cran? for coxme.? But > there is no error without as-cran nor is there one when I run the code in a terminal window. > > ismat <- function(x)? inherits(x, "matrix") || inherits(x, "bdsmatrix") || inherits(x, > "Matrix") > if (ismat(kmat)? ) .... > > (The second line is repeated multiple times for multiple arguments.? The ismat function is > defined simply to save typing.) > > The check log contains multiple instances of the lines below: > > < Warning message: > < In if (ismat(kmat)) { : > <??...
2010 Apr 06
0
Strange error
Someone just sent me a data set that causes the lmekin function, part of the kinship package, to fail. In chasing it down I get an error I have never seen before. fit <- lmekin(icam1 ~ factor(center) + age + factor(sex), random= ~1|iid, data=chaidata, varlist=kmat) Error in Y - fitted : non-numeric argument to binary operator Add the recover option, and the offending lines are fitted <- c(X %*% lfit$coef) #fitted, on the original scale residuals <- Y - fitted > options(error=recover) > fit <- lmekin(icam1 ~ factor(center) + age + fa...
2012 Nov 09
0
Kinship2 and GenABEL
Hi, I'm using kinship2 to calculate heritabilty, but I would like calculate in GenABEL too. I trying the code: > require(kinship2) > require(GenABEL) > pedig = with(Dados, pedigree(id=IID, dadid=PAT, momid=MAT, sex=SEX, famid=FID, missid=0)) > kmat = kinship(pedig) > (mod1 = polygenic(altura ~ SEX + idade, data=Dados, kin=kmat)) Erro em intI(i, n = d[1], dn[[1]], give.dn = FALSE) : invalid character indexing > How can I calculate heritabilty using GenABEL with kinship matrix of kinship2 package? Thanks, ---------------------------...
2020 Jan 13
0
as-cran issue ==> set _R_CHECK_LENGTH_1_* settings!
...by the --as-cran > option > >>> > >>> [...] > >>> > >>> | The check log contains multiple instances of the lines below: > >>> | > >>> | < Warning message: > >>> | < In if (ismat(kmat)) { : > >>> | < the condition has length > 1 and only the first element will > be > >>> used > >>> | > >>> | I don't see how the error could arise, but if I know what > as-cran is > >>> doing perhaps I...
2020 Jan 14
5
as-cran issue ==> set _R_CHECK_LENGTH_1_* settings!
...n >> >>> >> >>> [...] >> >>> >> >>> | The check log contains multiple instances of the lines below: >> >>> | >> >>> | < Warning message: >> >>> | < In if (ismat(kmat)) { : >> >>> | < the condition has length > 1 and only the first element will >> be >> >>> used >> >>> | >> >>> | I don't see how the error could arise, but if I know what >> as-cran is &...