Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Returned JSON difficult to parse #36

Closed
analystguy opened this issue Sep 3, 2019 · 3 comments
Closed

Returned JSON difficult to parse #36

analystguy opened this issue Sep 3, 2019 · 3 comments
Labels

Comments

@analystguy
Copy link

First - thanks for the great tools. I am rather new to Python and am having difficulty parsing the returned json into a dataframe. Is there a plan in the works to do so or can anyone offer assistance?
The json returned appears as one long unstructured dictionary string.

@sylvandb
Copy link
Contributor

sylvandb commented Sep 4, 2019

Isn't the returned data a dict or maybe a list of dict?
if you print(value) it will convert whatever it is into a string

you can experiment interactively with python, and try type(value)

alternatively, if somehow you do have a string containing json data then:

import json
value = json.loads(string_value)

@sabirjana
Copy link

Hello, great work!! Is there an easy way to get data in pandas dataframe from various supported methods ?
Thanks

@JECSand
Copy link
Owner

JECSand commented Sep 13, 2019

Hi analystguy,

Here is an example I posted showing how to use YahooFinancials with Pandas.

https://github.com/JECSand/pandas_sqlalchemy_technical_analysis/blob/master/pandas_with_sqlalchemy.py

Thanks!

@JECSand JECSand closed this as completed Sep 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants