## ---- dsetup,echo = false,结果=“ hide”,include = false ----------------------------------------------------------------------------------{library(biocsklearn)库(biocstyle)})## ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------库(Biocsklearn)## ----------------------------------------------------------------------------------------------------------- np = nticulate :: import(“ numpy”,convert = false,delay_load = true)irloc = system.file(“ csv/iris.csv”,package =“ biocsklearn”)irismat = np $genfromtxt(irloc,delimiter =',')## ---- dota,eval = true --------------------------------------------------------------------------------------------------------------------------------------------- np$take(irismat, 0:2, 0L ) ## ----dor------------------------------------------------------------------------------------------------------------- fullPC = prcomp(data.matrix(iris [,1:4]))$ x ## -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- tx = getTransformed(ppca)dim(tx)头(TX)## ----------------ONC ---------------------------------------------------------------------------------------------------圆形(Cor(TX,FullPC),3)## --------------------------------------------------------------------------------------------- ippca = skIncrPCA(iris [,1:4])#mat)#ippcab = skincrpca(iris [,1:4],batch_size = 25l)round(cor(getTransformed(ippcab),fullpc),3)## ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------eval = true ------------------------------------------------------------------------------------------------------------------------------ ta = np $ take#提供切片机实用程序IPC = skpartialpca_step(ta(irismat,0:49,0L))ipc = skpartialpca_step(ta(irismat,50:99,0L),OBJ = ipc)IPC= skpartialpca_step(ta(irismat,100:149,0L),obj = ipc)ipc $ transform(ta(irismat,0:5,0l))fullpc [1:5,]