[R] Sum Column in data.frame for Excel-Export

PIKAL Petr petr.pikal at precheza.cz
Mon Nov 19 08:20:39 CET 2012


Hi

maybe

?rbind

Petr

> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of Mat
> Sent: Friday, November 16, 2012 3:42 PM
> To: r-help at r-project.org
> Subject: [R] Sum Column in data.frame for Excel-Export
> 
> Hello together,
> 
> I have a data.frame, which I would like to export to excel.
> This works without problems. My problem is, that i can't sum one of the
> colums.
> 
> If i try this, i get the sum of this column.
> > sum_PT_PROG<-sum(data_export_final_sort$PT_PROG,na.rm=TRUE)
> > sum_PT_PROG
> [1] 130
> 
> But how can i get this result under my column for the Excel Export?
> Now my Excel Export looks like this one.
> PT_PROG
> 23
> 100
> 7
> 
> and now i want under this digets the sum of this column (130)?
> 
> Thanks for your help.
> 
> Mat
> 
> 
> 
> --
> View this message in context: http://r.789695.n4.nabble.com/Sum-Column-
> in-data-frame-for-Excel-Export-tp4649744.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-
> guide.html
> and provide commented, minimal, self-contained, reproducible code.




More information about the R-help mailing list