Harika22 commited on
Commit
4ab08c6
·
verified ·
1 Parent(s): c298ce7

Update pages/6_Semi_structured_data.py

Browse files
Files changed (1) hide show
  1. pages/6_Semi_structured_data.py +8 -1
pages/6_Semi_structured_data.py CHANGED
@@ -317,7 +317,9 @@ elif file_type == "JSON":
317
  ''')
318
  st.markdown('''
319
  - Output will be :
320
- output = '{"0":{"name":"harii","age":21,"weight":34},"1":{"name":"sree","age":24,"weight":45},"2":{"name":"gowtham","age":25,"weight":67}}'
 
 
321
  ''')
322
 
323
  st.subheader("Orient as Columns...")
@@ -330,6 +332,11 @@ elif file_type == "JSON":
330
  data = pd.read_json(a)
331
  col = data.to_json(orient="columns")
332
  col
 
 
 
 
 
333
  output = '{"name":{"0":"harii","1":"sree","2":"gowtham"},"age":{"0":21,"1":24,"2":25},"weight":{"0":34,"1":45,"2":67}}'
334
  ''')
335
 
 
317
  ''')
318
  st.markdown('''
319
  - Output will be :
320
+ ''')
321
+ st.code('''
322
+ output = '{"0":{"name":"harii","age":21,"weight":34},"1":{"name":"sree","age":24,"weight":45},"2":{"name":"gowtham","age":25,"weight":67}}'
323
  ''')
324
 
325
  st.subheader("Orient as Columns...")
 
332
  data = pd.read_json(a)
333
  col = data.to_json(orient="columns")
334
  col
335
+ ''')
336
+ st.markdown('''
337
+ - Output will be:
338
+ ''')
339
+ st.code('''
340
  output = '{"name":{"0":"harii","1":"sree","2":"gowtham"},"age":{"0":21,"1":24,"2":25},"weight":{"0":34,"1":45,"2":67}}'
341
  ''')
342