简体   繁体   English

R 中的 PCA:svd(x,nu=0,nv=k)中的错误:“x”中的值无限或缺失

[英]PCA in R: Error in svd(x, nu=0, nv=k) : Infinite or missing values in 'x'

My dataframe contains about 26k rows with 129 variables.我的 dataframe 包含大约 26k 行和 129 个变量。 I've made sure all of the variables are numeric and do not have any NA values (used na.omit).我确保所有变量都是数字的并且没有任何 NA 值(使用 na.omit)。 Using the function prcomp() on my dataframe tells me "Infinite or missing values in x".在我的 dataframe 上使用 function prcomp() 告诉我“x 中有无限或缺失值”。 What might I be overlooking then?那我可能会忽略什么?

Did you also make sure none of them are infinite?您是否还确保它们都不是无限的? As that's the other part of that message?因为那是那条信息的另一部分?

Easily check all this with:通过以下方式轻松检查所有这些:

all( is.finite( your.data.frame ) )

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 svd(x, nu = 0, nv = k) 中的错误:“x”中的值无限或缺失。 矩阵中没有 NA 或 Inf 值 - Error in svd(x, nu = 0, nv = k) : infinite or missing values in 'x'. There are no NA or Inf values in matrix svd(x,nu = 0)中的错误:'x'中的值无限或缺失(检查是否存在负值) - Error in svd(x, nu = 0) : infinite or missing values in 'x' (checked no negative values exist) R - svd()函数 - 'x'中的无限或缺失值 - R - svd() function - infinite or missing values in 'x' R MASS软件包中的lm.ridge()说“ svd(X)中的错误:'x'中的值无穷或缺失” - lm.ridge() in R MASS package saying “Error in svd(X) : infinite or missing values in 'x'” R:采样:校准函数:svd(X)中的错误:“ x”中的值无穷或缺失 - R: Sampling: Calib function: Error in svd(X) : infinite or missing values in 'x' 计算R错误中的SVD:缺失值或无限值 - Calculate SVD in R error: missing or infinite values svd(x,nu = 0)中的错误:0范围尺寸 - Error in svd(x, nu = 0) : 0 extent dimensions La.svd(x, nu, nv) 中的错误:在 ClustOfVar 中使用稳定性函数时,来自 Lapack 例程“dgesdd”的错误代码 1 - Error in La.svd(x, nu, nv) : error code 1 from Lapack routine 'dgesdd' when using stability function in ClustOfVar svd(X)中的错误:'x'中的值无穷或缺失。 在GAS中使用BacktestVaR时 - Error in svd(X) : infinite or missing values in 'x' . when using BacktestVaR in GAS R-'x'中的无穷或缺失值 - R - Infinite or missing values in 'x'
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM