Skip to content

Instantly share code, notes, and snippets.

@samueleresca
Created August 18, 2020 22:38
Show Gist options
  • Save samueleresca/794619e6822c9d599c95e49f9de83e82 to your computer and use it in GitHub Desktop.
Save samueleresca/794619e6822c9d599c95e49f9de83e82 to your computer and use it in GitHub Desktop.
internal abstract class ScanShareableAnalyzer<S, M> : Analyzer<S, M>, ...
{
...
public override Option<S> ComputeStateFrom(DataFrame dataFrame)
{
IEnumerable<Column> aggregations = AggregationFunctions();
Row result = dataFrame
.Agg(aggregations.First(), aggregations.Skip(1).ToArray())
.Collect()
.FirstOrDefault();
return FromAggregationResult(result, 0);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment