Math.scan | R Documentation |
Mathematical and arithmetic operations on param's, scan's and pvol's
## S3 method for class 'scan'
Math(x, ...)
## S3 method for class 'pvol'
Math(x, ...)
## S3 method for class 'param'
Ops(e1, e2)
## S3 method for class 'scan'
Ops(e1, e2)
## S3 method for class 'pvol'
Ops(e1, e2)
x |
object of class |
... |
objects passed on to the Math functions |
e1 |
object of class |
e2 |
object of class |
Use caution when applying these manipulations, as there are no consistency checks if the operations lead to interpretable outcomes. For example, when averaging scans with logarithmic values (e.g. DBZ), it might be required to first exponentiate the data before summing.
Attributes are taken from the first object in the operation.
When a pvol
is multiplied by a list, in which case arguments are taken from the list per scan.
this requires the list to have the same length as the number of scans.
an object of the input class
calculate_param()
# Locate and read the polar volume example file
scan1 <- example_scan
#add a value of 1 to all scan parameters:
scan2 <- example_scan + 1
# average the scan parameters of two scans:
# NB: requires identical scan parameter names and order!
(scan1 + scan2)/2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.