module

Crysda::DataFrame

A "tabular" data structure representing cases/records (rows), each of which consists of a number of observations or measurements (columns) DataFrame is an immutable object, any mutation will return a new object.

Instance methods

plot

Returns a PlotBuilder for more complex plot configurations

Source
plot_area(x : String, *y_cols : String) : Cryplot::Plot

Stacked area chart for time series composition

Source
plot_bar(x : String, y : String) : Cryplot::Plot

Draw a bar chart

Source
plot_box(*columns : String) : Cryplot::Plot

Draw a box plot for one or more columns Note: Cryplot doesn't have native box plot support, so we simulate with error bars

Source
plot_correlation

Plot correlation matrix as a heatmap for numeric columns

Source
plot_density(*columns : String) : Cryplot::Plot

Density plot (KDE only, no histogram)

Source
plot_distribution(column : String, bins : Int32 = 20, *, kde : Bool = true) : Cryplot::Plot

Distribution plot - histogram with optional KDE overlay

Source
plot_errorbar(x : String, y : String, yerr : String) : Cryplot::Plot

Scatter/line plot with error bars

Source
plot_grouped_bar(x : String, *y_cols : String) : Cryplot::Plot

Grouped bar chart - bars side by side for each category

Source
plot_heatmap(x : String, y : String, value : String) : Cryplot::Plot

Heatmap from three columns (x categories, y categories, values) Pivots the data and displays as heatmap

Source
plot_hexbin(x : String, y : String, bins : Int32 = 20) : Cryplot::Plot

Hexagonal binning for large datasets

Source
plot_histogram(column : String, bins : Int32 = 10) : Cryplot::Plot

Draw a histogram

Source
plot_line(x : String, y : String, *, sorted : Bool = false) : Cryplot::Plot

Draw a line plot with x and y columns Set sorted: true to sort by x values (useful for time series)

Source
plot_line(x : String, *y_cols : String, sorted : Bool = false) : Cryplot::Plot

Draw a line plot with multiple y series Set sorted: true to sort by x values (useful for time series)

Source
plot_pairplot

Pairplot - grid of scatter plots for all numeric column pairs Diagonal shows histograms, off-diagonal shows scatter plots

Source
plot_pie(label_col : String, value_col : String) : Cryplot::Plot

Pie chart

Source
plot_qq(column : String) : Cryplot::Plot

Q-Q plot for normality check

Source
plot_regression(x : String, y : String) : Cryplot::Plot

Scatter plot with linear regression line and R² annotation

Source
plot_scatter(x : String, y : String) : Cryplot::Plot

Draw a scatter plot

Source
plot_stacked_bar(x : String, *y_cols : String) : Cryplot::Plot

Stacked bar chart for multiple y columns

Source
plot_stem(x : String, y : String) : Cryplot::Plot

Stem/lollipop chart

Source
plot_value_counts(label_col : String | Nil = nil, count_col : String = "n") : Cryplot::Plot

Quick bar chart from value_counts result Usage: df.value_counts("category").plot_value_counts

Source