0

これが私が実行しているものです。エラーが発生する理由と、エラーの意味/修正方法を知りたいです。CDdat の null 値を取得することと何か関係がありますか? 誰にもアイデアがありますか?ありがとう。

library(phytools)
Loading required package: ape
Loading required package: maps

library(adephylo)
Loading required package: ade4

library(geiger)
library(nlme)
library(evomap)
library(caper)
Loading required package: MASS
Loading required package: mvtnorm

library(scales)

Attaching package: ‘scales’

The following object is masked from ‘package:geiger’:

    rescale

library(coda)
library(ggplot2); theme_set(theme_light())
library(HDInterval)

Frogtree<-read.nexus("C:/Users/WiensDell3/Desktop/TwilliamsRfiles_AdvertisementCalls/frog_contree")

Call.duration. <- read.csv("C:/Users/WiensDell3/Desktop/TwilliamsRfiles_AdvertisementCalls/Call duration .csv")

CD <- Call.duration.

mydata<-comparative.data(data= CD,phy= Frogtree, names.col= "Species")

FrogTree<- mydata$phy

mydata2 <-mydata$data

x <- mydata2$CD
BMsigma2 <- ace(x, FrogTree, method = "REML")$sigma2[1]
mvBMresults <- mvBM(x, FrogTree, BMsigma2)
tree_mvBMCD <- FrogTree; tree_mvBMCD$edge.length<-mvBMresults$rBL
CDdat<- mydata2$CD; names(CDdat <-rownames(mydata2)
+ )
NULL
Iterations <- 500000

Model_mvBMCD<-anc.Bayes(tree_mvBMCD,CDdat,ngen=Iterations)
Error in invC %*% X : requires numeric/complex matrix/vector arguments

Model_mvBMCD<-anc.Bayes(tree_mvBMCD,CDdat,ngen=Iterations)
Error in invC %*% X : requires numeric/complex matrix/vector arguments
4

0 に答える 0