metrics | R Documentation |
Get metrics defined by template points.
metrics(stimuli, formula = c(0, 1))
stimuli |
list of stimuli with tems |
formula |
a vector of two points to measure the distance apart, or a string of the formula for the metric |
Reference x and y coordinates by point number like x[0]
or y[188]
. Use any R functions to process the numbers, as well as pow()
(same as ^()
, for consistency with webmorph.org). Remember that 0,0 is the top left for images; e.g., min(y[0], y[1])
gives your the higher of the two pupil y-coordinates.
named vector of the metric
Other info:
add_info()
,
compare()
,
get_info()
,
get_point()
,
height()
,
rename_stim()
,
width()
stimuli <- demo_stim() metrics(stimuli, c(0, 1)) # eye-spacing # face width-to-height ratio fwh <- "abs(max(x[113],x[112],x[114])-min(x[110],x[111],x[109]))/abs(y[90]-min(y[20],y[25]))" metrics(stimuli, fwh)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.