[R-es] CONSULTA f

Freddy Omar López Quintero freddy.vate01 en gmail.com
Dom Nov 3 16:19:59 CET 2013


Hola.

No sé si estoy entendiendo correctamente, pero ¿por qué no ubicas en el
archivo csv los nombres de las columnas directamente?

Con el archivo adjunto, creado a partir de la información que das, he
corrido las líneas que mencionas:

library(FactoMineR)
res.pca<- read.csv('antibioticos.csv',h=T,row.names=1)
res.hcpc <- HCPC(res.pca, nb.clust=0, conso=0, min=3, max=10)

Y todo ha funcionado correctamente.

Saludos.


2013/11/3 Dr. José A Betancourt Bethencourt <jbetancourt en iscmc.cmw.sld.cu>

> ESTE SCRIPT FUNCIONA PERFECTAMENTE, LA PREGUNTA QUE HACÍA SE REFERÍA A QUE
> SI SERÍA POSIBLE QUE EN LA PROPIA TABLA CSV PUDIERAN ESTAR LOS NOMBRES DE
> LOS ANTIBIOTICOS Y QUE EL ANÁLISIS PCA NO LO RECHACE POR SER CUALITATIVO,
> QUE DE ALGUNA MANERA SE DIERA UNA INSTRUCCIÓN PARA EVITAR TENER QE HACER LO
> DE rownames manualmente
>
>
>
> setwd("D:/Public/Documents/R/FactoMineR/")
>
> table1 <- read.table(file="antibioticos.csv", header=T, as.is=T,
>
>                        sep=";")
>
>
>
> rownames(table1) <-
> c("Ampicillin","Oxacillin","Peniclina","Ciprofloxacina","Amikacina","Gentamicina","Kanamicina","Ceftriaxone","Ceftazidima","Cefotaxima","Cefazolina","Cefuroxima","Aztreonam","Cloranfenicol","Vancomicina","Eritromicina","Clindamicina","Fosfomicina","Amoxicilina","Imipenem","Azitromicina","Ampicillin/Sulbactan")
>
>
>
> library(FactoMineR)
>
>
>
>
>
> res.hcpc <- HCPC(res.pca, nb.clust=0, conso=0, min=3, max=10)
>
> _______________________________________________
> R-help-es mailing list
> R-help-es en r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-help-es
>
>


-- 
«But Gwindor answered: 'The doom lies in yourself, not in your name.'»

JRR Tolkien
------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: <https://stat.ethz.ch/pipermail/r-help-es/attachments/20131103/56147767/attachment.html>
------------ próxima parte ------------
A non-text attachment was scrubbed...
Name: antibioticos.csv
Type: text/csv
Size: 597 bytes
Desc: no disponible
URL: <https://stat.ethz.ch/pipermail/r-help-es/attachments/20131103/56147767/attachment.bin>


Más información sobre la lista de distribución R-help-es