max Questions

3

Solved

I am currently learning about the built-in functions in Julia, specifically max and maximum, and I am seeking clarification on their differences. julia> max(1, 2, 3, 4) 4 julia> maximum([1, 2...
Wateriness asked 10/6, 2023 at 13:31

14

Solved

The method should work like Math.Max(), but take 3 or more int parameters.
Incarnadine asked 23/7, 2011 at 13:55

4

I want to select the maximum value in a dataframe, and then find out the index and the column name of that value. Is there a way to do it? Say, in the example below, I want to first find the max v...
Recalescence asked 13/11, 2016 at 1:19

7

Solved

I am trying to get the max value from a panda dataframe as a whole. I am not interested in what row or column it came from. I am just interested in a single max value within the DataFrame. Here is ...
Hubby asked 4/7, 2014 at 9:27

7

I have this question that has completely stumped me. I have to create a variable that equals Integer.MAX_VALUE... (in Java) // The answer must contain balanced parentesis public class Exercise{ ...
Cobnut asked 6/4, 2014 at 1:31

2

Solved

My question is similar to this. But for strings. So I have a dataframe, each column contains strings of different length. So, how I can find the maximum string length per column? Then, how to se...
Ayr asked 5/3, 2016 at 19:46

6

Solved

Assume to have a torch tensor, for example of the following shape: x = torch.rand(20, 1, 120, 120) What I would like now, is to get the indices of the maximum values of each 120x120 matrix. To s...
Haymes asked 8/11, 2018 at 16:53

6

Solved

I have a simple array formula in excel that doesn't work in the way I wish. In columns A and B there is data (A1 is paired with B1 and so on) while in column F there is the calculation based on the...
Mccarthyism asked 21/8, 2015 at 17:32

8

I have a list of objects how can I run a query to give the max value of a field: I'm using this code: def get_best_argument(self): try: arg = self.argument_set.order_by('-rating')[0].details e...
Hypomania asked 10/5, 2009 at 2:58

8

Solved

I have an array of size 1000. How can I find the indices (indexes) of the five maximum elements? An example with setup code and my attempt are displayed below: Random rand = new Random(); int[] ...
Aborning asked 12/7, 2013 at 20:25

5

Solved

I have a list of floats in R. For a given integer, N, I want to find the indices of the largest N values in my list. So for example, if N is 2, I want to find the indices of the two largest values ...
Afghani asked 12/7, 2013 at 16:39

14

How can I find out the min and the max date from an array of dates? Currently, I am creating an array like this: var dates = []; dates.push(new Date("2011/06/25")) dates.push(new Date("2011/06/26"...
Carl asked 22/8, 2011 at 5:10

3

Solved

I have written an algorithm is Swift for finding the maximum value and its index in a Swift array. This is inspired by the "max.m" function in Matlab & Octave. Could the experts here suggest a...
Canara asked 9/2, 2017 at 5:31

5

Solved

I'm trying to find what is the most effective way to get the longest string in a string array. For example : let array = ["I'm Roi","I'm asking here","Game Of Thrones is just good"] and the outc...
Antiquary asked 27/4, 2016 at 13:23

10

I have a mongodb collection like: db.kids.find() //results [ {name:'tom', age:10}, {name:'alice', age:12}, .... ] I need a query to get MAX 'age' from this collection like in SQL: SELECT MAX(...
Solvent asked 18/8, 2015 at 15:18

31

Solved

For <input type="number"> element, maxlength is not working. How can I restrict the maxlength for that number element?
Dyad asked 2/12, 2011 at 10:33

17

Solved

Below is my pseudo code. function highest(i, j, k) { if(i > j && i > k) { return i; } else if (j > k) { return j; } else { return k; } } I think that works, but is t...
Wildfowl asked 9/2, 2010 at 23:0

3

Solved

I'd like to change the labels for the colorbar from increasing to decreasing values. When I try to do this via vmin and vmax I get the error message: minvalue must be less than or equal to maxva...
Excitant asked 30/5, 2013 at 1:57

7

Solved

Lets say that I have a table which contains a column for invoice number, the data type is VARCHAR with mixed string/int values like: invoice_number ************** HKL1 HKL2 HKL3 ..... HKL12 ...
Af asked 11/5, 2013 at 12:3

3

Solved

I have a function using SSE to do a lot of stuff, and the profiler shows me that the code portion I use to compute the horizontal minimum and maximum consumes most of the time. I have been using t...
Garrotte asked 7/3, 2014 at 17:17

2

Solved

I'm trying to get x and y coordinates of all cumulative maximums in a vector. I wrote a naive for-loop but I have a feeling there is some way to do it with numpy that's more elegant. Does anyone k...
Jailbird asked 19/4, 2018 at 17:44

15

I have a navigation bar on the left hand side of my page, and I want it to stretch to 100% of the page height. Not just the height of the viewport, but including the areas hidden until you scroll. ...
Grandiose asked 3/4, 2009 at 5:50

4

using Postgres 9.3... Can someone please explain why I can't use a max function directly on an unnested array..? It is my understanding the unnest function returns a "setof" just like the select ...
Margaux asked 5/2, 2015 at 18:23

5

Solved

I have a DataFrame like this one: Communications and Search Business General Lifestyle 0 0.745763 0.050847 0.118644 0.084746 0 0.333333 0.000000 0.583333 0.083333 0 0.617021 0.042553 0.297872 0.042...
Absence asked 28/4, 2015 at 12:18

21

Solved

NumPy proposes a way to get the index of the maximum value of an array via np.argmax. I would like a similar thing, but returning the indexes of the N maximum values. For instance, if I have an arr...
Dumah asked 2/8, 2011 at 10:29

© 2022 - 2025 — McMap. All rights reserved.