Name
SPVM::R::OP::DataFrame - Data Frame Operations
Description
R::OP::DataFrame class in SPVM has methods for operations for data frame.
Usage
use R::OP::DataFrame as DFOP;
use R::OP::Int as IOP;
use R::OP::Double as DOP;
use R::OP::String as STROP;
my $data_frame1 = DFOP->data_frame;
$data_frame1->set_col("name", STROP->c(["Ken", "Yuki", "Mike"]));
$data_frame1->set_col("age", IOP->c([19, 43, 50]));
$data_frame1->set_col("weight", DOP->c([(double)50.6, 60.3, 80.5]));
my $data_frame2 = DFOP->data_frame;
$data_frame1->set_col("name", STROP->c(["Jonh"]));
$data_frame1->set_col("age", IOP->c([25]));
$data_frame1->set_col("weight", DOP->c([(double)40.6]));
my $data_frame3 = DFOP->cbind($data_frame1, $data_frame2);
Class Methods
cbind
static method cbind : R::DataFrame ($x_data_frame : R::DataFrame, $y_data_frame : R::DataFrame);
rbind
static method rbind : R::DataFrame ($x_data_frame : R::DataFrame, $y_data_frame : R::DataFrame);
See Also
Copyright & License
Copyright (c) 2024 Yuki Kimoto
MIT License