Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Add copy buttons to all
 blocks
(function() {
function addCopyButtons() {
document.querySelectorAll('pre code').forEach(function(codeBlock) {
if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;
codeBlock.parentElement.setAttribute('data-copy-added', 'true');
var btn = document.createElement('button');
btn.textContent = 'Copy';
btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';
btn.onmouseover = function() { this.style.opacity = '1'; };
btn.onmouseout = function() { this.style.opacity = '0.7'; };
btn.onclick = function() {
navigator.clipboard.writeText(codeBlock.textContent).then(function() {
btn.textContent = 'Copied!';
setTimeout(function() { btn.textContent = 'Copy'; }, 1500);
});
};
codeBlock.parentElement.style.position = 'relative';
codeBlock.parentElement.appendChild(btn);
});
}
addCopyButtons();
// Re-run on dynamic content
var observer = new MutationObserver(addCopyButtons);
observer.observe(document.body, { childList: true, subtree: true });
})();
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Force GitHub README to respect dark mode (function() { var style = document.createElement('style'); style.textContent = ' .markdown-body { color-scheme: dark light; } .markdown-body pre { background: #161b22 !important; } .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; } .markdown-body table th, .markdown-body table td { border-color: #30363d !important; } .markdown-body img { background: #0d1117; } .markdown-body blockquote { border-left-color: #8b949e; } .markdown-body hr { border-color: #30363d; } '; document.head.appendChild(style); })(); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ' Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Highlight search terms from Google/DuckDuckGo/Bing referrer (function() { var ref = document.referrer; var terms = []; if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) { var url = new URL(ref); var q = url.searchParams.get('q') || url.searchParams.get('p'); if (q) { terms = q.split(/\s+/).filter(function(t) { return t.length > 2; }); } } if (terms.length === 0) return; var style = document.createElement('style'); style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }'; document.head.appendChild(style); function highlight(node) { if (node.nodeType === 3) { // text node var text = node.textContent; var found = false; terms.forEach(function(term) { var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\]\\]/g, '\\') + ')', 'gi'); if (regex.test(text)) { found = true; var frag = document.createDocumentFragment(); var parts = text.split(regex); parts.forEach(function(part, i) { if (i % 2 === 0) { frag.appendChild(document.createTextNode(part)); } else { var span = document.createElement('span'); span.className = 'userscript-highlight'; span.textContent = part; frag.appendChild(span); } }); node.parentNode.replaceChild(frag, node); } }); } else if (node.nodeType === 1 && node.childNodes) { // element var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT']; if (!skipTags.includes(node.tagName)) { Array.from(node.childNodes).forEach(highlight); } } } highlight(document.body); // Re-highlight on dynamic content var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1 || node.nodeType === 3) highlight(node); }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ' Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Strip utm_, fbclid, gclid, etc. from all links on page (function() { var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content', 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid', 'ref', 'ref_src', 'source', 'medium', 'campaign']; function cleanUrl(url) { try { var u = new URL(url, window.location.origin); var changed = false; trackingParams.forEach(function(p) { if (u.searchParams.has(p)) { u.searchParams.delete(p); changed = true; } }); return changed ? u.toString() : url; } catch (e) { return url; } } function cleanLinks() { document.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } cleanLinks(); var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1) { if (node.tagName === 'A') cleanLinks(); node.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + ' Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Auto-enable theater mode on YouTube (function() { function tryTheater() { var btn = document.querySelector('button[aria-label="Theater mode"], ytd-player #player button[title="Theater mode"]'); if (btn && !btn.classList.contains('activated')) { btn.click(); } } // Try immediately tryTheater(); // Try after navigation (SPA) var lastUrl = location.href; setInterval(function() { if (location.href !== lastUrl) { lastUrl = location.href; setTimeout(tryTheater, 500); } }, 1000); // Also try on player load var observer = new MutationObserver(tryTheater); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ' Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Remove or un-stick sticky/fixed headers that block content (function() { function unstick() { document.querySelectorAll('header, nav, [role="banner"], .header, .navbar, .sticky, .fixed-top, [style*="position: fixed"], [style*="position:sticky"]').forEach(function(el) { if (el.style.position === 'fixed' || el.style.position === 'sticky' || getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') { el.style.position = 'static'; el.style.top = 'auto'; el.style.zIndex = 'auto'; } }); } unstick(); var observer = new MutationObserver(unstick); observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] }); })(); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ' Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock
, 'i'); if (__m === '*' || __re.test(location.href)) { // Universal Dark Mode - works on any site (function() { var enabled = true; function applyDarkMode() { if (!enabled) return; // Create style element if it doesn't exist var style = document.getElementById('universal-dark-mode-style'); if (!style) { style = document.createElement('style'); style.id = 'universal-dark-mode-style'; document.head.appendChild(style); } // Dark mode CSS - inverts colors but preserves images/video style.textContent = ' /* Invert everything except media */ html { filter: invert(1) hue-rotate(180deg) !important; background: #1a1a2e !important; } /* Restore images, videos, iframes, canvas */ img, video, iframe, canvas, svg, picture, [style*="background-image"] { filter: invert(1) hue-rotate(180deg) !important; } /* Preserve specific elements that should not be inverted */ .no-dark-mode, .no-dark-mode *, [data-theme="light"], [data-theme="light"], .ace_editor, .ace_editor *, .CodeMirror, .CodeMirror *, .monaco-editor, .monaco-editor *, .markdown-body pre, .markdown-body pre *, .highlight, .highlight *, pre code, pre code * { filter: none !important; } /* Fix common UI elements */ .modal, .popup, .dropdown-menu, .tooltip, .popover { filter: invert(1) hue-rotate(180deg) !important; background: #2d2d44 !important; border-color: #444 !important; } /* Scrollbars */ ::-webkit-scrollbar { background: #1a1a2e !important; } ::-webkit-scrollbar-thumb { background: #444 !important; } ::-webkit-scrollbar-thumb:hover { background: #555 !important; } /* Selection */ ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; } ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; } '; } function removeDarkMode() { var style = document.getElementById('universal-dark-mode-style'); if (style) style.remove(); } // Toggle with Alt+Shift+D document.addEventListener('keydown', function(e) { if (e.altKey && e.shiftKey && e.key === 'D') { e.preventDefault(); enabled = !enabled; if (enabled) { applyDarkMode(); console.log('[Universal Dark Mode] Enabled'); } else { removeDarkMode(); console.log('[Universal Dark Mode] Disabled'); } } }); // Apply on load applyDarkMode(); // Re-apply on dynamic content var observer = new MutationObserver(function(mutations) { if (enabled && !document.getElementById('universal-dark-mode-style')) { applyDarkMode(); } }); observer.observe(document.head, { childList: true }); console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle'); })(); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })(); Carson scales free by cpsievert · Pull Request #167 · plotly/plotly.R · GitHub
Skip to content

Carson scales free - #167

Merged
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free
Mar 11, 2015
Merged

Carson scales free#167
chriddyp merged 12 commits into
plotly:masterfrom
cpsievert:carson-scales-free

Conversation

@cpsievert

Copy link
Copy Markdown
Collaborator

Howdy @chriddyp@mkcor@tdhock!

The purpose of this pull request is to fully implement facet_wrap(..., scales = 'free').

It also seems possible to implement space = "free", but perhaps that should be in a separate pull request.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

You might find this script I wrote helpful for comparing the output of gg2list() between two different package versions. When I Rscript json-diffs.R, I can see colorized diffs in my console like this:

screen shot 2015-02-17 at 6 26 14 pm

Installing from GitHub is perhaps inefficient, but it might be worth avoiding nasty git checkout errors. Let me know if any ideas on how to improve it!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Ah, crud. I messed with the white space a bit which makes the last commit diff hard to read. You can add ?w=1 to the end of url to ignore whitespace, for example, this is better to look at

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Regarding whitespaces, I go for RStudio's indentation. In this respect, it looks like some of your whitespace changes are 'fixes', so that's all good. I'm not sure about others (see inline comments).

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Please keep it the way RStudio does indentation.

Copy link
Copy Markdown
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, no good reason. I'll change that back

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet. That's what I prefer to.

I also prefer

f<-function() {
print("hi")
}

over

f<-function() {
print("hi")
}

so I'd be happy to change that as well

@chriddyp

Copy link
Copy Markdown
Member

Nice! hey @tdhock is it possible/easy to run that test table on this branch?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I'm pretty sure Toby's current implementation would only support visual testing of one branch at a time. Perhaps we could do something similar in a "username.github.com" repo with a folder for each branch?

@tdhock

Copy link
Copy Markdown
Contributor

yes it should be possible to run the test table on this branch, but I will need to do a little hacking. Will post a link to the updated table when I get a chance to work on it.

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Sweet, thanks @tdhock! Will toby-fixes be merged into master soonish? Or maybe we should merge carson-scales-free and toby-fixes?

@chriddyp

Copy link
Copy Markdown
Member

Cool - @tdhock@mkcor - should we move these *.r files that have the cookbook examples branch (https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite) into the testhat directory (or elsewhere) in master so that the test-table can pick up on that rich set of examples?
@tdhock I'm assuming that checkout out the add-r-cookbook branch and running those additional tests would add too much complexity to your table generating script (https://github.com/ropensci/plotly-test-table/blob/gh-pages/index.R)? @mkcor if your opposed to having these non-test scripts inside that folder, then maybe we can move them somewhere else, like a plotly/scripts folder or @tdhock maybe we can move them into the plotly-test-table repo to be included?
i'd love to just visually inspect all of the examples in the facets chapter (https://github.com/ropensci/plotly/blob/add-r-cookbook-tests/tests/cookbook-test-suite/facets.r) before merging this PR

@tdhock

Copy link
Copy Markdown
Contributor

@cpsievert I don't know how long it will be before toby-fixes it merged into master, so I would suggest to pull changes from toby-fixes into your branch.

@chriddyp@mkcor I agree that it is a good idea to add examples from the cookbook branch to the test table. In my opinion the easiest way to do this would be to just add them as tests/testthat/test-*.R files under toby-fixes. I can do that if you guys tell me which of

https://github.com/ropensci/plotly/tree/add-r-cookbook-tests/tests/cookbook-test-suite

you would like to include... or would you like to include all of the *.r and *.R files?

@chriddyp

Copy link
Copy Markdown
Member

@tdhock OK, that sounds good. All of them are good except multiple_graphs_on_one_page.r

@mkcor

Copy link
Copy Markdown
Contributor

@mkcor

Copy link
Copy Markdown
Contributor

@tdhock@chriddyp Definitely, let's include the cookbook examples as regular .R files (not .r) under tests/testthat/. But please create a new branch for this and keep each PR as small as possible!!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhocktoby-fixes could be merged sooner if it was smaller. The bigger the PR, the longer it takes to review. It should not be toby-fixes in the first place: There should be toby-errorbar-horizontal, toby-box-scales-free, etc. Each branch and corresponding PR should address one issue.

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert@tdhock For reference, https://github.com/ropensci/plotly/wiki/Development-guidelines#a-few-guidelines -- Thanks @chriddyp for updating and cleaning that up!

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Can you please revert c542520 ? You shouldn't find yourself merging another feature/dev/wip branch into your own feature branch. Merging master makes sense if it has changed meanwhile (basically, you would be merging toby-fixes indirectly, because it would have been merged into master, but this is not the case).
Once you revert this merge, I can do a final review.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@mkcor ok, I removed that merge from the history on this branch

@mkcor

Copy link
Copy Markdown
Contributor

@cpsievert Amazing! Just pulled your branch for a quick final review.

Comment threadR/ggplotly.R Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tdhock

Copy link
Copy Markdown
Contributor

by the way do you want to get added to ropensci so you can add a branch under the main plotly repos for your next branch/PR? i guess it doesn't really matter but I figured I would ask.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Thanks @tdhock. I'll hopefully have a fix soon. It'd be nice to be added, but not essential.

@chriddypchriddyp mentioned this pull request Mar 9, 2015
@chriddyp

Copy link
Copy Markdown
Member

Hey @cpsievert - how is this going? anything I can do to help get this through? A few users wrote in about scales-free this weekend!

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I just updated the test table (note that it didn't update automatically because this PR was initiated from my fork).

http://ropensci.github.io/plotly-test-table/

I don't see any problems, and I'd be OK with merging now, but we can certainly add more of the cookbook tests if you'd like.

@chriddyp

Copy link
Copy Markdown
Member

Fantastic, the visual tests look good! 👍 from me

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Cool, thanks. Should I wait for a +1 from @mkcor?

@chriddyp

Copy link
Copy Markdown
Member

@mkcor is on vacation till the end of the week, I think she'll be reviewing post-merge post-vacation. @tdhock could you take a closer look at the code for approval?

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, I actually just noticed a regression in facet strip labels. I'll fix later today and let everyone know when it's ready.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

Annotations are fixed now. Ready to merge when you are @chriddyp@tdhock

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock it appears your latest push to plotly-test-table somehow overwrote homepage links to commits I made earlier today --

http://ropensci.github.io/plotly-test-table/

You can still see them here though --

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/

@tdhock

Copy link
Copy Markdown
Contributor

The homepage links are generated via the files in tables/* so I think the links will show up the next time the table is re-made.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

@tdhock@chriddyp please have a look at the table and +1 (it looks good to me and I'm ready to merge)

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/

There was a failure in downloading contours (this seems to be quite common when I make locally):

http://ropensci.github.io/plotly-test-table/tables/f9e252af61276fd40168fc8916024877c7f2f6a3/contour.html

However, this test for the previous commit looks good (the only is difference is NEWS/DESCRIPTION)

http://ropensci.github.io/plotly-test-table/tables/f800c1249fc36072c1b4dd775b88659144b80f17/contour.html

@tdhock

Copy link
Copy Markdown
Contributor

are you sure it is a download error? If so there should be a log file... if there is not a log file then there is a bug in the plotly-test-table code.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I don't see a log -- here is what I see in my terminal

screen shot 2015-03-10 at 2 18 14 pm

@tdhock

Copy link
Copy Markdown
Contributor

If it is a download error you get a log line via this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I may need to add some code to attempt retries for the sending step as well.

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

OK, good to know, it's probably because I'm on a crappy wifi connection
right now. I don't think it should prevent this from being merged, agreed?

On Tue, Mar 10, 2015 at 2:42 PM, Toby Dylan Hocking <
notifications@github.com> wrote:

If it is a download error you get a log line via this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L248-L250

but you are seeing an error due to this code
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L265-L270

the only reason why I can think that would be happening is that the
py$ggplotly function returns an error
https://github.com/ropensci/plotly-test-table/blob/gh-pages/table.R#L233

that is the code for SENDING the plotly, not for downloading it. I guess I
may need to add some code to attempt retries for the sending step as well.


Reply to this email directly or view it on GitHub
#167 (comment).

@cpsievert

Copy link
Copy Markdown
CollaboratorAuthor

I made the table again (after merging with master which now has the fix for ribbon transparency) and everything looks good (with no caveats :)

http://ropensci.github.io/plotly-test-table/tables/bfa5bfef02ce059712ecb08d38106ddace3cd12e/index.html

Feel free to merge @chriddyp@tdhock 👍

@tdhock

Copy link
Copy Markdown
Contributor

+1

chriddyp added a commit that referenced this pull request Mar 11, 2015
@chriddyp
chriddyp merged commit d185f67 into plotly:masterMar 11, 2015
@cpsievert
cpsievert deleted the carson-scales-free branch March 13, 2015 01:55
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@cpsievert@mkcor@chriddyp@tdhock