search for: minresult

Displaying 1 result from an estimated 1 matches for "minresult".

2009 Jan 29
2
Taking the min of each row in a matrix
...rix will give me averages by row, but min and max give me the value for the entire matrix. I want the min (for example) of each row. pmin looks useful, but I can't seem to get the syntax right to apply to each column. Right now I am doing this. Is there a one-liner that would work instead? minResult <- vector (mode="list", length=rowCount) for (row in 1:rowCount) { minResult[[row]] <- min(corResult[row], na.rm = TRUE) } Thanks in advance. WILL