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

Error using google_analytics_account_list() #52

Closed
ilyasustun opened this issue Dec 23, 2016 · 5 comments
Closed

Error using google_analytics_account_list() #52

ilyasustun opened this issue Dec 23, 2016 · 5 comments

Comments

@ilyasustun
Copy link

Windows 10 64 bit.
R 3.3.2
RStudio Version 1.0.44

The code:
account_list = google_analytics_account_list()

returns the following error:

Error : df is not a data frame
API Data failed to parse.  Returning parsed from JSON content.
                    Use this to test against your data_parse_function.

How can it be solved?

@MarkEdmondson1234
Copy link
Collaborator

I've seen this before when the email authenticated under has no GA Views to list, or only one - could this be the case?

@ilyasustun
Copy link
Author

Well I have one project yes, or one View. But why would one ga view give an error?

@MarkEdmondson1234
Copy link
Collaborator

R treats one row data.frames as vectors sometimes, but I've not had an account to test it upon with only one View.

Its recommended anyhow not to just have one, since ideally you should have a raw data profile then another with filters applied against bots etc.

But this also should not be a problem since a previous fix I did, so may I ask what version of the package you are using? Typing the output of the below will give all the info needed:

sessionInfo()

And also to see if the same problem persists if you install the development version:

Install devtools if you don't have it:

install.packages(devtools)

Then install via Github:

library(devtools)
install_github("MarkEdmondson1234/googleAnalyticsR")

Note also that you should still be getting data in the account_list object, just not in a data.frame, so if you still have a problem see if you can paste the output of str(account_list) then I can see if its a bug I can fix.

@MarkEdmondson1234
Copy link
Collaborator

MarkEdmondson1234 added a commit that referenced this issue Dec 28, 2016
@MarkEdmondson1234
Copy link
Collaborator

@mischa2002k2 @ilyasustun I found the bug for parsing the account summary when its only one row, its fixed now for the version on github

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants