ChartDataset<T>
ChartForgeX.Data
Represents an immutable, renderer-neutral collection of source rows that can be transformed before chart construction.
Inheritance
- object
- ChartDataset<T>
Usage
Explore 13 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 10
- Property ChartDataBin<T>.Dataset
- Property ChartDataGroup<T1, T2>.Dataset
- Method ChartDataset<T>.Bin
- Method ChartDataset<T>.Filter
- Method ChartDataset<T>.From
- Method ChartDataset<T>.Select``1
- Method ChartDataset<T>.SortByDescending``1
- Method ChartDataset<T>.SortBy``1
- Method ChartDataset<T>.Summarize``2
- Property ChartDataset<T>.Empty
Accepted by parameters 3
- Method Chart.AddHistogram``1
- Method ChartGrid.FromFacets``2
- Method ChartGrid.FromFacets``2
Type Parameters
- T
- The source row type.
Methods
public ChartDataset<ChartDataBin<T?>> Bin(Func<T?, double> valueSelector, int binCount) #Partitions a numeric measure into the same rounded, equal-width layout used by scalar histogram ingestion.
Parameters
- valueSelector System.Func<T?, double>
- binCount int
public ChartDataset<ChartDataBin<T?>> Bin(Func<T?, double> valueSelector, ChartHistogramBinLayout layout) #Partitions measurements through an explicit shared layout, preserving empty intervals and rejecting observations outside intervals or in gaps.
Parameters
- valueSelector System.Func<T?, double>
- layout ChartForgeX.Core.ChartHistogramBinLayout
public ChartDataset<T?> Filter(Func<T?, bool> predicate) #Returns rows accepted by the predicate without changing this dataset.
Parameters
- predicate System.Func<T?, bool>
Returns
ChartDataset<T?>public static ChartDataset<T?> From(IEnumerable<T?> rows) #Materializes a source sequence once into an immutable dataset.
Parameters
- rows System.Collections.Generic.IEnumerable<T?>
Returns
ChartDataset<T?>public IEnumerator<T?> GetEnumerator() #Returns an enumerator over the dataset rows in insertion order.
Returns
IEnumerator<T?>public IReadOnlyList<ChartDataGroup<TKey?, T?>> GroupBy<TKey>(Func<T?, TKey?> keySelector, IEqualityComparer<TKey?>? comparer = null) #Groups rows by key while preserving first-key and source-row order.
Type Parameters
- TKey
Parameters
- keySelector System.Func<T?, TKey?>
- comparer System.Collections.Generic.IEqualityComparer<TKey?>? = null
Returns
IReadOnlyList<ChartDataGroup<TKey?, T?>>public ChartDataset<TResult?> Select<TResult>(Func<T?, TResult?> selector) #Projects every row into a new immutable dataset.
Type Parameters
- TResult
Parameters
- selector System.Func<T?, TResult?>
Returns
ChartDataset<TResult?>public ChartDataset<T?> SortByDescending<TKey>(Func<T?, TKey?> keySelector, IComparer<TKey?>? comparer = null) #Returns rows ordered descending by the selected key without changing this dataset.
Type Parameters
- TKey
Parameters
- keySelector System.Func<T?, TKey?>
- comparer System.Collections.Generic.IComparer<TKey?>? = null
Returns
ChartDataset<T?>public ChartDataset<T?> SortBy<TKey>(Func<T?, TKey?> keySelector, IComparer<TKey?>? comparer = null) #Returns rows ordered by the selected key without changing this dataset.
Type Parameters
- TKey
Parameters
- keySelector System.Func<T?, TKey?>
- comparer System.Collections.Generic.IComparer<TKey?>? = null
Returns
ChartDataset<T?>public ChartDataset<TResult?> Summarize<TKey, TResult>(Func<T?, TKey?> keySelector, Func<TKey?, IReadOnlyList<T?>, TResult?> summarize, IEqualityComparer<TKey?>? comparer = null) #Creates one summary row per group.
Type Parameters
- TKey
- TResult
Parameters
- keySelector System.Func<T?, TKey?>
- summarize System.Func<TKey?, System.Collections.Generic.IReadOnlyList<T?>, TResult?>
- comparer System.Collections.Generic.IEqualityComparer<TKey?>? = null
Returns
ChartDataset<TResult?>