Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

bash python csv to json

cat my.csv | python -c 'import csv, json, sys; print(json.dumps([dict(r) for r in csv.DictReader(sys.stdin)]))'
Comment

PREVIOUS NEXT
Code Example
Python :: pandas return specific row 
Python :: ordereddict 
Python :: flask port 
Python :: seaborn boxplot 
Python :: np one hot encoding 
Python :: create django group 
Python :: seaborn correlation heatmap 
Python :: python sum array 
Python :: remove last line of text file python 
Python :: move column in pandas 
Python :: create a blank image cv2 
Python :: dataframe KeyError: 
Python :: how to find the data type in python 
Python :: django get form data from post 
Python :: python remove characters from end of string 
Python :: python how to draw a square 
Python :: clicking a button in selenium python 
Python :: Origin in CORS_ORIGIN_WHITELIST is missing scheme or netloc 
Python :: python slicing nested list 
Python :: apply lambda function to multiple columns pandas 
Python :: cut rows dataframe 
Python :: keep only one duplicate in pandas 
Python :: python parentheses 
Python :: pandas df filter by time hour 
Python :: reshape wide to long in pandas 
Python :: difference between supervised and unsupervised learning 
Python :: add one row to dataframe 
Python :: pd.dataframe initial columns 
Python :: view all columns in pandas dataframe 
Python :: convert list to dataframe 
ADD CONTENT
Topic
Content
Source link
Name
8+9 =