Struct blackjack::dataframe::DataFrame[][src]

pub struct DataFrame { /* fields omitted */ }

Struct for holding Series or [SeriesTrait] like objects. as well as adding some additional functionality by grouping them.

Methods

impl DataFrame
[src]

Create a new DataFrame struct

Example

use blackjack::prelude::*;

let mut df = DataFrame::new();

Read a CSV file into a DataFrame where each column represents a Series supports automatic decompression of gzipped files if they end with .gz

Example

use blackjack::prelude::*;
 
let path = format!("{}/tests/data/basic_csv.csv.gz", env!("CARGO_MANIFEST_DIR"));
let df = DataFrame::read_csv(&path, b',').unwrap();
 
assert_eq!(df["col1"].sum::<i32>(), 15);
 

Trait Implementations

impl Default for DataFrame
[src]

Returns the "default value" for a type. Read more

impl Debug for DataFrame
[src]

Formats the value using the given formatter. Read more

impl Display for DataFrame
[src]

Formats the value using the given formatter. Read more

impl DataFrameBehavior for DataFrame
[src]

Transform into a raw pointer

Get a DataFrame from raw pointer

impl ColumnManager for DataFrame
[src]

Add a new series to the dataframe as a column.

Get a reference to a series by name, will also have to know the primitive type stored. Read more

Same as ColumnManager::get_column but as a mut reference.

Get the number of columns

Return the current dataframe's columns

impl<S: Into<String>> Index<S> for DataFrame
[src]

The returned type after indexing.

Performs the indexing (container[index]) operation.

impl<S: Into<String>> IndexMut<S> for DataFrame
[src]

Performs the mutable indexing (container[index]) operation.

Auto Trait Implementations

impl Send for DataFrame

impl Sync for DataFrame