medianareamat.Rd 1.06 KB
 1 2 3 4 5 6 % Generated by roxygen2: do not edit by hand % Please edit documentation in R/operationareamat.R \name{medianareamat} \alias{medianareamat} \title{Function for getting the median value of an area on a matrix.} \usage{  Ahmad Alkadri committed Jul 18, 2019 7 medianareamat(m, rowmin=1, rowmax, colmin=1, colmax)  8 9 10 } \arguments{ \item{m}{A matrix object}  Ahmad Alkadri committed Jul 10, 2019 11   Ahmad Alkadri committed Jul 18, 2019 12 \item{rowmin}{The first row for subsetting. Default value is 1.}  Ahmad Alkadri committed Jul 10, 2019 13   Ahmad Alkadri committed Jul 18, 2019 14 \item{rowmax}{The last row for subsetting.}  Ahmad Alkadri committed Jul 10, 2019 15   Ahmad Alkadri committed Jul 18, 2019 16 \item{colmin}{The first column for subsetting. Default value is 1.}  Ahmad Alkadri committed Jul 10, 2019 17   Ahmad Alkadri committed Jul 18, 2019 18 \item{colmax}{The last column for subsetting.}  19 20 21 22 23 24 25 26 27 28 29 30 31 32 } \value{ The median value of the subsetted area of matrix m } \description{ A function for calculating the median value of an area of a matrix. For example if we want to get the median value of part of a 10x10 matrix, starting from 2nd column, 1st row to 3rd row, 5th column, we'll get the values of this smaller matrix (3x4 to be precise) and then we'll calculate the median of all of them. } \examples{ m <- matrix(rnorm(100, mean = 0, sd = 1), nrow = 10, ncol = 10) medianarea <- medianareamat(m, rowmin = 1, rowmax = 3, colmin = 2, colmax = 5) }