Comments (3)
Ah sorry, thanks for flagging! I think I've fixed it to handle larger files now (will deploy in the next 10 min)!
from housing-data.
Thanks for adding this; there might be a bug with the json formatting for my comparison chart. I'm getting a json string parsing error:
From browser:
SyntaxError: JSON.parse: unterminated string at line 1 column 72714 of the JSON data
From pandas:
`---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
Cell In[3], line 1
----> 1 df = pd.read_json(data_dir / 'housing data comparisons.json')
2 df.head()
File /opt/homebrew/Caskroom/miniconda/base/envs/mapping/lib/python3.11/site-packages/pandas/io/json/_json.py:804, in read_json(path_or_buf, orient, typ, dtype, convert_axes, convert_dates, keep_default_dates, precise_float, date_unit, encoding, encoding_errors, lines, chunksize, compression, nrows, storage_options, dtype_backend, engine)
802 return json_reader
803 else:
--> 804 return json_reader.read()
File /opt/homebrew/Caskroom/miniconda/base/envs/mapping/lib/python3.11/site-packages/pandas/io/json/_json.py:1014, in JsonReader.read(self)
1012 obj = self._get_object_parser(self._combine_lines(data_lines))
1013 else:
-> 1014 obj = self._get_object_parser(self.data)
1015 if self.dtype_backend is not lib.no_default:
1016 return obj.convert_dtypes(
1017 infer_objects=False, dtype_backend=self.dtype_backend
1018 )
File /opt/homebrew/Caskroom/miniconda/base/envs/mapping/lib/python3.11/site-packages/pandas/io/json/_json.py:1040, in JsonReader._get_object_parser(self, json)
1038 obj = None
1039 if typ == "frame":
-> 1040 obj = FrameParser(json, **kwargs).parse()
1042 if typ == "series" or obj is None:
1043 if not isinstance(dtype, bool):
File /opt/homebrew/Caskroom/miniconda/base/envs/mapping/lib/python3.11/site-packages/pandas/io/json/_json.py:1173, in Parser.parse(self)
1172 def parse(self):
-> 1173 self._parse()
1175 if self.obj is None:
1176 return None
File /opt/homebrew/Caskroom/miniconda/base/envs/mapping/lib/python3.11/site-packages/pandas/io/json/_json.py:1366, in FrameParser._parse(self)
1362 orient = self.orient
1364 if orient == "columns":
1365 self.obj = DataFrame(
-> 1366 ujson_loads(json, precise_float=self.precise_float), dtype=None
1367 )
1368 elif orient == "split":
1369 decoded = {
1370 str(k): v
1371 for k, v in ujson_loads(json, precise_float=self.precise_float).items()
1372 }
ValueError: Unmatched ''"' when when decoding 'string'`
from housing-data.
Here is what the chart looks like, in case this depends on the chart configuration.
from housing-data.
Related Issues (6)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from housing-data.