ecpEnergyTwinCommonTools icon

ecpEnergyTwinCommonTools

Energy Twin Tools used by other ET extensions
ecpEnergyTwinCommonToolsAxon funcs

Registered StackHub users may elect to receive email notifications whenever a new package version is released or a comment is posted on the forum.

There are 0 watchers.

v1.0.3

ettClusterDegreeDays
ettClusterDegreeDays(point, span)

Returns degree days using XQuery.

ettClusterDegreeDaysBase
ettClusterDegreeDaysBase(point)

Returns degree days base using XQuery.

ettClusterHisRead
ettClusterHisRead(point, span, opts: {})

Returns history grid using XQuery.

ettClusterIsIdLocal
ettClusterIsIdLocal(id)

Checks if id of record is in local project.

ettClusterToOccupiedPoint
ettClusterToOccupiedPoint(point)

Returns occupied point using XQuery.

ettClusterToRec
ettClusterToRec(point)

Returns record using XQuery.

ettClusterToWeatherPoint
ettClusterToWeatherPoint(point)

Returns weather point using XQuery.

ettClusterXq
ettClusterXq(opts: {})

Returns new XQuery.

ettClusterXqExecute
ettClusterXqExecute(xquery)

Executes XQuery with tracing options.

ettDerivative
ettDerivative(grid)

Calculates derivation. Input should be cumulative data.

For example:

10kWh
19kWh
31kWh
38kWh

Calculation:

(row.kWh - lastRow.kWh) / (row.ts - lastRow.ts)
ettFileExists
ettFileExists(uri)

Checks if file exists.

ettFoldAnyTrue
ettFoldAnyTrue(val, acc)

Folds to true if any of value is true.

ettFoldDayCount
ettFoldDayCount(val, ts, acc)

Fold to count days.

ettFoldDiff
ettFoldDiff(val, ts, acc)

Fold to calculate difference between last and first.

ettFoldIntegral
ettFoldIntegral(val, ts, acc)

Fold to integrate.

ettFoldMode
ettFoldMode(val, acc)

Fold to most occuring value.

ettGridAxisJoin
ettGridAxisJoin(data, cols: null, chartGroup: 0, minModifier: 0, maxModifier: 0)

Joins grid axis, used when different units need to have same y axis.

ettGridColMetaToPresentation
ettGridColMetaToPresentation(data, yAxisColumnOrder: [], xAxisCol: "ts")

Converts column meta to presentation on grid.

ettGridFindValidRows
ettGridFindValidRows(grid, cns: null)

Finds rows that have valid values (ettValueIsValid) in columns.

Examples:

ettGridFindValidRows(grid)                 // checks all columns in all rows
ettGridFindValidRows(grid, "v0")           // checks v0 in all rows
ettGridFindValidRows(grid, ["v0", "v2"])   // checks v0 and v2 in all rows
ettGridSetHisMeta
ettGridSetHisMeta(data, span: null, timezone: null)

Adds hisStart and hisEnd to grid based on span or on data in grid.

ettIntegral
ettIntegral(grid)

Calculates integral.

ettRelative
ettRelative(meas, pred)

Relative difference of measurement and prediction.

ettRoundTo
ettRoundTo(number, maxDecimals)

Rounds number to specified decimal place.

ettUnitConversions
ettUnitConversions()

Unit conversion dictionary.

ettUnitDerivativeToIntegral
ettUnitDerivativeToIntegral(derivativeUnit)

Converts unit from derivative to integral.

ettUnitIntegralToDerivative
ettUnitIntegralToDerivative(integralUnit)

Converts unit from integral to derivative.

ettValueIsValid
ettValueIsValid(value)

Check if value is valid (not null, not NA, not NaN).

Examples:

ettValueIsValid(true)    >>   true
ettValueIsValid(123)     >>   true
ettValueIsValid(null)    >>   false
ettValueIsValid(na())    >>   false
ettValueIsValid(nan())   >>   false
Published by Energy Twin

Products & Services by Energy Twin

Packages by Energy Twin

Commercial packages

Free packages