Python Forum
Sorting data by specific variables using argparse
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Sorting data by specific variables using argparse
#5
That should work. You don't need argparse. The only thing here is that you read all the lines of the file "csvinput" in your program between lines 4 and 11. So when the program reaches line 18, there is nothing left to read. Solution: close the file after line 11 and re-open it before line 18.
Reply


Messages In This Thread
RE: Sorting data by specific variables using argparse - by ibreeden - Jan-01-2023, 12:51 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Data Sorting and filtering(From an Excel File) PY_ALM 0 1,171 Jan-09-2023, 08:14 PM
Last Post: PY_ALM
  Training a model to identify specific SMS types and extract relevant data? lord_of_cinder 0 1,078 Oct-10-2022, 04:35 AM
Last Post: lord_of_cinder
Question Sorting data with pandas TheZaind 4 2,557 Nov-22-2021, 07:33 PM
Last Post: aserian
  Searching a .txt file for a specific number and extracting the corresponding data nrozman 3 3,359 Jul-27-2018, 02:07 PM
Last Post: nrozman
  How to filter specific rows from large data file Ariane 7 8,467 Jun-29-2018, 02:43 PM
Last Post: gontajones
  Plotting climate data with NetCdf files for a specific region with coordinates fyec 3 5,606 Jun-27-2018, 12:34 PM
Last Post: buran
  A small data sorting program - couple of general and hopefully easy questions Ansifatcat 2 3,042 Jan-25-2018, 05:29 AM
Last Post: Ansifatcat
  Replacing values for specific columns in Panda data structure Padowan 1 14,780 Nov-27-2017, 08:21 PM
Last Post: Padowan

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020