Properties

new CoordinateSystem(options)

Parameter

Name Type Optional Description

options

 

 

Fires
module:meteoJS/thermodynamicDiagram/coordinateSystem#change:options

Properties

public

height  integer

Visible height, in pixels.

public

width  integer

Visible width, in pixels.

Methods

_normalizeTemperatureRange()

getPByXY(x, y) → number

Pressure for a x-y coordinate. Implementation valid for horizontal isobars, log-P y-axes.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

y

number

 

Pixels from bottom.

Returns

number Pressure in hPa.

getTByXP(x, p) → number

Temperature for pressure and x coordinate. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

p

number

 

Pressure in hPa.

Returns

number Temperature in Kelvin.

getTByXY(x, y) → number

Temperature for x-y coordinate. Implementation valid for straight isotherms.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

y

number

 

Pixels from bottom.

Returns

number Temperature in Kelvin.

getXByPEquiPotTemp(p, thetae) → number

x coordinate for pressure and equipotential temperature . Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

thetae

number

 

Equipotential temperaturen in Kelvin.

Returns

number Pixels from the left.

getXByPHMR(p, hmr) → number

x coordinate for pressure and humid mixing ratio. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

hmr

number

 

Humid mixing ratio. []

Returns

number Pixels from the left.

getXByPPotentialTemperatur(p, T) → number

x coordinate for pressure and potential temperature. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

T

number

 

Potential temperature in Kelvin.

Returns

number Pixels from the left.

getXByPT(p, T) → number

x coordinate for pressure and temperature. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

T

number

 

Temperature in Kelvin.

Returns

number Pixels from the left.

getXByYEquiPotTemp(y, thetae) → number

x coordinate for equipotential temperature and y coordainte. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

y

number

 

Pixels from bottom.

thetae

number

 

Equipotential temperaturen in Kelvin.

Returns

number Pixels from the left.

getXByYHMR(y, hmr) → number

x coordinate for humid mixing ratio and y coordinate. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

y

number

 

Pixels from bottom.

hmr

number

 

Humid mixing ratio. []

Returns

number Pixels from the left.

getXByYPotentialTemperature(y, T) → number

x coordinate for potential temperature and y coordinate. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

y

number

 

Pixels from bottom.

T

number

 

Potential temperature in Kelvin.

Returns

number Pixels from the left.

getXByYT(y, T) → number

x coordinate for temperature and y coordinate. Implementation valid for straight isotherms.

Parameters

Name Type Optional Description

y

number

 

Pixels from bottom.

T

number

 

Temperature in Kelvin.

Returns

number Pixels from the left.

getYByPEquiPotTemp(p, thetae) → (number or undefined)

y coordinate for pressure and equipotential temperature . Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

thetae

number

 

Equipotential temperaturen in Kelvin.

Returns

(number or undefined) Pixels from bottom.

getYByPHMR(p, hmr) → (number or undefined)

y coordinate for pressure and humid mixing ratio. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

hmr

number

 

Humid mixing ratio. []

Returns

(number or undefined) Pixels from bottom.

getYByPPotentialTemperatur(p, T) → number

y coordinate for pressure and potential temperature. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

T

number

 

Potential temperature in Kelvin.

Returns

number Pixels from bottom.

getYByPT(p, T) → number

y coordinate for pressure and temperature. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

p

number

 

Pressure in hPa.

T

number

 

Temperature in Kelvin.

Returns

number Pixels from bottom.

getYByXEquiPotTemp(x, thetae) → (number or undefined)

y coordinate for equipotential temperature and x coordinate. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

thetae

number

 

Equipotential temperaturen in Kelvin.

Returns

(number or undefined) Pixels from bottom.

getYByXHMR(x, hmr) → (number or undefined)

y coordinate for humid mixing ratio and x coordinate. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

hmr

number

 

Humid mixing ratio. []

Returns

(number or undefined) Pixels from bottom.

getYByXP(x, p) → number

y coordinate for pressure and x coordinate. Implementation valid for horizontal isobars, log-P y-axes.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

p

number

 

Pressure in hPa.

Returns

number Pixels from bottom.

getYByXPotentialTemperature(x, T) → (number or undefined)

y coordinate for potential temperature and x coordinate. Implementation valid for horizontal isobars, log-P y-axes and straight isotherms.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

T

number

 

Potential temperature in Kelvin.

Returns

(number or undefined) Pixels from bottom.

getYByXT(x, T) → (number or undefined)

y coordinate for temperature and x coordinate. Implementation valid for straight isotherms.

Parameters

Name Type Optional Description

x

number

 

Pixels from the left.

T

number

 

Temperature in Kelvin.

Returns

(number or undefined) Pixels from bottom.

isDryAdiabatStraightLine() → boolean

Returns if the dry adiabats are straight lines in the defined coordinate system.

Returns

boolean 

isIsobarsStraightLine() → boolean

Returns if isobars are straight lines in the defined coordinate system.

Returns

boolean 

isIsothermsVertical() → boolean

Returns

boolean 

update([options])

Updates options. To restore a default value, pass undefined.

Parameters

Name Type Optional Description

options

Object

Yes

Options.

Values in options have the following properties:

Name Type Optional Description

pressure

module:meteoJS/thermodynamicDiagram/coordinateSystem~pressureOptions

Yes

Pressure options.

temperature

module:meteoJS/thermodynamicDiagram/coordinateSystem~temperatureOptions

Yes

Temperature options.