Documentation
¶
Overview ¶
Package syinsyra provides first-class Insyra integration for Syralit. Import with alias syi:
import syi "github.com/HazelnutParadise/syralit/integrations/insyra"
Index ¶
- func AreaChart(dt *insyra.DataTable, xCol, yCol string)
- func BarChart(dt *insyra.DataTable, xCol, yCol string)
- func CCLBuilder(dt *insyra.DataTable, opts ...sy.Option) *insyra.DataTable
- func ColumnSelect(label string, dt *insyra.DataTable, opts ...sy.Option) string
- func Correlation(dt *insyra.DataTable, colX, colY, method string)
- func CorrelationMatrix(dt *insyra.DataTable, method string, opts ...sy.Option)
- func Describe(dt *insyra.DataTable, opts ...sy.Option)
- func EditableList(dl *insyra.DataList, opts ...sy.Option) []any
- func EditableTable(dt *insyra.DataTable, opts ...sy.Option) [][]any
- func FilterBuilder(dt *insyra.DataTable, opts ...sy.Option) *insyra.DataTable
- func Histogram(dl *insyra.DataList, bins int, opts ...sy.Option)
- func LineChart(dt *insyra.DataTable, xCol, yCol string)
- func LinearRegression(dt *insyra.DataTable, yCol string, xCols ...string)
- func List(dl *insyra.DataList, opts ...sy.Option)
- func ListAreaChart(dl *insyra.DataList, opts ...sy.Option)
- func ListBarChart(dl *insyra.DataList, opts ...sy.Option)
- func ListDescribe(dl *insyra.DataList, opts ...sy.Option)
- func ListLineChart(dl *insyra.DataList, opts ...sy.Option)
- func ListMetrics(dl *insyra.DataList)
- func ListPreview(dl *insyra.DataList, n int, opts ...sy.Option)
- func Metrics(dt *insyra.DataTable, col string)
- func ParseTable(name string, data []byte) (*insyra.DataTable, error)
- func PieChart(dt *insyra.DataTable, labelCol, valueCol string)
- func Preview(dt *insyra.DataTable, n int, opts ...sy.Option)
- func ScatterChart(dt *insyra.DataTable, xCol, yCol string)
- func ScatterFromLists(xName, yName string, x, y *insyra.DataList)
- func TTest(dt *insyra.DataTable, col1, col2 string, equalVariance bool)
- func Table(dt *insyra.DataTable, opts ...sy.Option)
- func UploadTable(label string, opts ...sy.Option) *insyra.DataTable
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CCLBuilder ¶ added in v0.3.0
CCLBuilder renders an interactive CCL (column-computation language) box that adds a computed column to a DataTable and returns the result, also rendering it. The source table is never mutated. The formula is applied only when the user presses Apply, and each evaluation is time-bounded — a formula that fails or runs away is reported in the UI and not applied, so it can never hang or crash the app.
Example formula (referencing columns by their index letter): A * B + 1
func ColumnSelect ¶
ColumnSelect renders a SelectBox populated with the DataTable's column names.
func Correlation ¶ added in v0.3.0
Correlation renders the correlation coefficient and p-value between two numeric columns as Metric widgets.
func CorrelationMatrix ¶ added in v0.3.0
CorrelationMatrix renders the pairwise correlation matrix of a DataTable's numeric columns. method is "pearson" (default), "spearman", or "kendall".
func Describe ¶ added in v0.3.0
Describe renders a full summary table (count, mean, std, min, quartiles, max, …) for every column of a DataTable, using Insyra's DataTable.Describe.
func EditableList ¶
EditableList renders a DataList as an editable single-column table and returns the current values reflecting user edits.
func EditableTable ¶
EditableTable renders an Insyra DataTable as an editable table. Returns the current rows reflecting user edits.
func FilterBuilder ¶ added in v0.3.0
FilterBuilder renders an interactive row filter over a DataTable (column + operator + value) and returns the filtered DataTable, also rendering it. The source table is never mutated (it operates on a Clone). Use the returned table for downstream steps (charts, stats, …).
func Histogram ¶
Histogram renders the distribution of a numeric DataList across the given number of bins. This is unique to lists — there is no DataTable equivalent.
func LineChart ¶
LineChart extracts two columns from a DataTable and renders a line chart. xCol provides x-axis labels, yCol provides numeric y values.
func LinearRegression ¶ added in v0.3.0
LinearRegression fits yCol against one or more xCols and renders the fit (R², adjusted R², coefficients with std error / t / p). For a single predictor it also shows the equation and a scatter of the data.
func List ¶
List renders an Insyra DataList as a single-column Syralit DataFrame. The column header is the list's name (or "Value" if unnamed).
func ListAreaChart ¶
ListAreaChart renders a DataList's numeric values as an area chart over index.
func ListBarChart ¶
ListBarChart renders a DataList's numeric values as a bar chart over index.
func ListDescribe ¶
ListDescribe renders a pandas-style summary table for a numeric DataList: count, mean, std, min, 25%, 50% (median), 75%, max.
func ListLineChart ¶
ListLineChart renders a DataList's numeric values as a line chart over their index. The series is named after the list.
func ListMetrics ¶
ListMetrics renders summary statistics for a numeric DataList (count, mean, min, max) as a row of Metric widgets.
func ListPreview ¶
ListPreview renders the first n values of a DataList as a single-column table.
func Metrics ¶
Metrics renders summary statistics for a numeric column as Metric widgets. It is shorthand for ListMetrics on the named column.
func ParseTable ¶ added in v0.3.0
ParseTable parses raw file bytes into a DataTable by file-name extension. Exposed so callers can parse files from sources other than the uploader (embedded assets, downloads, …).
func ScatterChart ¶
ScatterChart extracts x and y columns and renders a scatter chart.
func ScatterFromLists ¶ added in v0.3.0
ScatterFromLists renders a scatter chart from two equal-length DataLists.
func TTest ¶ added in v0.3.0
TTest renders an independent two-sample t-test between two numeric columns.
func UploadTable ¶ added in v0.3.0
UploadTable renders a file uploader and parses the uploaded file into an Insyra DataTable. The format is detected from the file extension: .csv, .xlsx/.xls, and .json are supported. Returns nil until a valid file is uploaded; parse errors are surfaced in the UI.
Parquet is intentionally not handled here — it would drag Apache Arrow into every app that uses this adapter. Read parquet directly with github.com/HazelnutParadise/insyra/parquet and pass the result to Table.
Types ¶
This section is empty.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package syiplot renders Insyra's go-echarts charts (insyra/plot) inline in a Syralit app, unlocking interactive chart types Syralit's built-in Chart.js layer doesn't have — Sankey, word cloud, K-line, gauge, funnel, theme-river, box plot, radar, and more.
|
Package syiplot renders Insyra's go-echarts charts (insyra/plot) inline in a Syralit app, unlocking interactive chart types Syralit's built-in Chart.js layer doesn't have — Sankey, word cloud, K-line, gauge, funnel, theme-river, box plot, radar, and more. |