search for: single_col_max

Displaying 4 results from an estimated 4 matches for "single_col_max".

2018 Feb 20
0
Take the maximum of every 12 columns
The maximum over twelve columns is the maximum of the twelve maxima of each of the columns. single_col_max <- apply(x, 2, max) twelve_col_max <- apply( matrix(single_col_max, nrow = 12), 2, max ) ir. Thierry Onkelinx Statisticus / Statistician Vlaamse Overheid / Government of Flanders INSTITUUT VOOR NATUUR- EN BOSONDERZOEK / RESEARCH INSTITUTE FOR NATURE AND FOREST Team Biometrie & Kwa...
2018 Feb 20
2
Take the maximum of every 12 columns
...into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Tue, Feb 20, 2018 at 7:05 AM, Thierry Onkelinx <thierry.onkelinx at inbo.be> wrote: > The maximum over twelve columns is the maximum of the twelve maxima of > each of the columns. > > single_col_max <- apply(x, 2, max) > twelve_col_max <- apply( > matrix(single_col_max, nrow = 12), > 2, > max > ) > > ir. Thierry Onkelinx > Statisticus / Statistician > > Vlaamse Overheid / Government of Flanders > INSTITUUT VOOR NATUUR- EN BOSONDERZOEK / RESEARCH INS...
2018 Feb 20
0
Take the maximum of every 12 columns
...ey Breathed in his "Bloom County" comic strip ) > > On Tue, Feb 20, 2018 at 7:05 AM, Thierry Onkelinx < > thierry.onkelinx at inbo.be> wrote: > >> The maximum over twelve columns is the maximum of the twelve maxima of >> each of the columns. >> >> single_col_max <- apply(x, 2, max) >> twelve_col_max <- apply( >> matrix(single_col_max, nrow = 12), >> 2, >> max >> ) >> >> ir. Thierry Onkelinx >> Statisticus / Statistician >> >> Vlaamse Overheid / Government of Flanders >> INSTITUUT...
2018 Feb 20
5
Take the maximum of every 12 columns
Dear all, I have monthly data in wide format, I am only providing data (at the bottom of the email) for the first 24 columns but I have 2880 columns in total. I would like to take max of every 12 columns. I have taken the mean of every 12 columns with the following code: byapply <- function(x, by, fun, ...) { # Create index list if (length(by) == 1) { nc <- ncol(x)