Comments (2)
Thank you, it fixed my problem, somehow my screenshot didn't upload. And glad to learn reprex package.
from tidyjson.
Hello! It would be helpful if you could share a reprex, so it is easier to understand what you are trying to accomplish!
In any case, the ..JSON
column disappears when you tell tidyjson
"Ok, I'm done with the JSON." The easiest way to do that is as_tibble()
. This moves you fully into the realm of dplyr
, tidyr
, etc. and drops the tbl_json
class:
library(tidyjson)
#>
#> Attaching package: 'tidyjson'
#> The following object is masked from 'package:stats':
#>
#> filter
tmp <- as_tbl_json('{"one": "two", "three": "four"}')
(make_it <- tmp %>% gather_object() %>% append_values_string())
#> # A tbl_json: 2 x 4 tibble with a "JSON" attribute
#> ..JSON document.id name string
#> <chr> <int> <chr> <chr>
#> 1 "\"two\"" 1 one two
#> 2 "\"four\"" 1 three four
make_it %>% as_tibble()
#> # A tibble: 2 x 3
#> document.id name string
#> <int> <chr> <chr>
#> 1 1 one two
#> 2 1 three four
Created on 2021-07-14 by the reprex package (v0.3.0)
from tidyjson.
Related Issues (20)
- Tidyr 1.0.0 new interface HOT 1
- CRAN 0.2.4 release checklist
- Parent array dropped when child array is empty HOT 5
- Getting 'argument "json.column" is missing' error, with no explanation why, cannot find troubleshooting documentation HOT 6
- Add append_values_* documentation
- Entering object drops records
- Implement a better `bind_rows()` HOT 1
- tidyjson 0.3.0 release HOT 1
- Add compatibility with dplyr programming data masking HOT 4
- `enter_object` won't work inside function HOT 1
- `json_chr()`, `json_dbl()` and `json_lgl()` are mentioned in the README but do not exist HOT 3
- Make `spread_values(.x, ...)` work more like `dplyr::mutate(.data, ...)`
- `enter_object` : allow keeping row if object does not exist HOT 4
- Using dplyr::group_by() with tbl_json objects changes the type of `..JSON` column HOT 6
- how to download Worldbank dataset with an api-call HOT 2
- how to use enter_object in function ?
- updates for purrr 1.0.0 HOT 2
- CRAN Release 0.3.2
- Automatic coercion from integer to character was deprecated in purrr 1.0.0. HOT 1
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 tidyjson.