473,287 Members | 1,926 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,287 software developers and data experts.

max() error

I've gotten this exact problem before and I was able to once figure it out. Since then i've apparently forgetten more of the basic.

Does anyone have any idea whats going on here, because fdayhigh is not an empty list...

Expand|Select|Wrap|Line Numbers
  1. >>> import justCup
  2. Traceback (most recent call last):
  3.   File "<interactive input>", line 1, in <module>
  4.   File "justCup.py", line 63, in <module>
  5.     CupStartIndex = fdayhigh.index(max(fdayhigh))
  6. ValueError: max() arg is an empty sequence
  7. >>> 
thanks
Oct 19 '07 #1
2 2373
ilikepython
844 Expert 512MB
I've gotten this exact problem before and I was able to once figure it out. Since then i've apparently forgetten more of the basic.

Does anyone have any idea whats going on here, because fdayhigh is not an empty list...

Expand|Select|Wrap|Line Numbers
  1. >>> import justCup
  2. Traceback (most recent call last):
  3.   File "<interactive input>", line 1, in <module>
  4.   File "justCup.py", line 63, in <module>
  5.     CupStartIndex = fdayhigh.index(max(fdayhigh))
  6. ValueError: max() arg is an empty sequence
  7. >>> 
thanks
Did you try printing fdayhigh before calling max()?
Oct 19 '07 #2
bartonc
6,596 Expert 4TB
Did you try printing fdayhigh before calling max()?
That's exactly what I would have said.
Does anyone have any idea whats going on here, because fdayhigh is not an empty list...
You may post the relevant section of that module in order for us to be able to help.
Oct 20 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Shekhar Mahadevan | last post by:
When I try installing, I get this: root# rpm -i MySQL-Max-4.1.0-0.i386.rpm warning: MySQL-Max-4.1.0-0.i386.rpm: V3 DSA signature: NOKEY, key ID 5072e1f5 error: Failed dependencies:...
0
by: Tom | last post by:
can anyone tell me whats wrong with the following from my.cnf? innodb_data_file_path =...
5
by: Bayla Frankl | last post by:
Hi all, I am a little stumped. I have a query I am trying to run to retrieve the last Progress Note record from the database for the current patient so that the therapists can see the last note...
5
by: kevinjouco | last post by:
Hello Have searched the group for a solution to the following problem without success: Table 1 has Ref No (No Duplicates) & Min Max Value Fields ie Ref No 1 Min 1 Max 10 Ref No 2 Min 11 Max...
2
by: Ike | last post by:
How can I select , for a given name, that record with the highest id for something like: id INTEGER(11) PRIMARY KEY NOT NULL AUTO_INCREMENT name VARCHAR(40) I want to select the highest id...
11
by: Angus | last post by:
Hello I am following the exercises in Accelerated C++ Practical Programming by Example and when use: using std::max; I get these compile errors in MS Visual C++ v6 error C2039: 'max' : is...
41
by: Gary Wessle | last post by:
Hi often I need to read numbers and only keep the highest or lowest. so I do something like int uLimit = 0; int lLimit = 999999999999; //hoping the compiler will not complain uLimit =...
10
by: james121285 | last post by:
I am having a problem with this program, I have been trying to do it all week and am stuck. I am writing a program that will take ten values from an input file, find the max and min then print them...
3
by: fperri | last post by:
I have a DB in Access 2002 that when it is ran on a few users computers in the company, they get the error that the file sharing lock count has been exceeded and to increase the max locks per file in...
6
by: rahulsengupta895 | last post by:
. #define MIN(a,b) (a<b?a:b) #define MAX(a,b) (a>b?a:b) #include "Video.h" #define NO_HUE -1
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: marcoviolo | last post by:
Dear all, I would like to implement on my worksheet an vlookup dynamic , that consider a change of pivot excel via win32com, from an external excel (without open it) and save the new file into a...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.