Module percept_analyzer

Utility functions to operate on percept data.

Description

Utility functions to operate on percept data. These functions should be considered experimental. Behaviour may change in future releases.

Function Index

activities2count/2Calculate the resulting active processes and ports during the activity interval.
activities2count/3
activities2count2/2
mean/1Calculates the mean and the standard deviation of a set of numbers.
minmax/1Returns the min and max of a set of 2-dimensional numbers.
minmax_activities/2Calculates the minimum and maximum of runnable activites (processes and ports) during the interval of reffered by the activity list.
seconds2ts/2Calculates a timestamp given a duration in seconds and a starting timestamp.
waiting_activities/1Calculates the time, both average and total, that a process has spent in a receive state at specific function.

Function Details

activities2count/2

activities2count(Acts::#activity{}, StartTs::timestamp()) -> Result

Calculate the resulting active processes and ports during the activity interval. Also checks active/inactive consistency. A task will always begin with an active state and end with an inactive state.

activities2count/3

activities2count(Acts, StartTs, Type) -> any()

activities2count2/2

activities2count2(Acts, StartTs) -> any()

mean/1

mean(List::[number()]) -> {Mean, StdDev, N}

Calculates the mean and the standard deviation of a set of numbers.

minmax/1

minmax(Data::[{X, Y}]) -> {MinX, MinY, MaxX, MaxY}

Returns the min and max of a set of 2-dimensional numbers.

minmax_activities/2

minmax_activities(Activities::[#activity{}], Count::integer()) -> {integer(), integer()}

Calculates the minimum and maximum of runnable activites (processes and ports) during the interval of reffered by the activity list.

seconds2ts/2

seconds2ts(Seconds::float(), StartTs::{integer(), integer(), integer()}) -> timestamp()

Calculates a timestamp given a duration in seconds and a starting timestamp.

waiting_activities/1

waiting_activities(Activities::[#activity{}]) -> FunctionList

Calculates the time, both average and total, that a process has spent in a receive state at specific function. However, if there are multiple receives in a function it cannot differentiate between them.


Generated by EDoc