Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 3867614

Browse files
committed
Merge branch 'source' into new-design-2016
# Conflicts: # _config_dev.yml # _includes/documentation_eg.html # _includes/head.html # _includes/lang-splash-banner.html # _includes/side-bar.html # _layouts/base.html # _layouts/langindex.html
1 parent 365ab51 commit 3867614

File tree

305 files changed

+100369
-2174
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

305 files changed

+100369
-2174
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ node_modules
1313
.Rhistory
1414
.sass-cache
1515
.DS_Store
16+
.jekyll-metadata

Contributing.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ The full bleed R pages are created with R Markdown. Here's how:
2323
$ git fetch origin
2424
$ git checkout source
2525
```
26-
2. [Install jekyll](http://jekyllrb.com/docs/installation/). **Important** - [Install the same version that GitHub is using: 2.4.0](https://pages.github.com/versions/):
26+
2. [Install jekyll](http://jekyllrb.com/docs/installation/). **Important** - Install Jekyll version 2.5.3:
2727

2828
```
29-
$ gem install jekyll -v 2.4.0
29+
$ gem install jekyll -v 2.5.3
3030
```
3131
3. Install a couple dependencies:
3232

@@ -71,6 +71,8 @@ To deploy, first install `_config.yml` package dependencies:
7171
documentation (source) $ sudo gem install jekyll-redirect-from
7272
documentation (source) $ sudo gem install jekyll-sitemap
7373
documentation (source) $ sudo gem install terminal-notifier
74+
documentation (source) $ sudo gem install jemoji
75+
documentation (source) $ sudo gem install redcarpet
7476
7577
```
7678

Rakefile_original

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
def git_clean?
2+
git_state = `git status 2> /dev/null | tail -n1`
3+
clean = (git_state =~ /working directory clean/)
4+
end
5+
6+
task :check_git do
7+
unless git_clean?
8+
puts "Dirty repo - commit or discard your changes and run deploy again"
9+
exit 1
10+
end
11+
end
12+
13+
desc "Deploy to remote origin"
14+
task :deploy => [:check_git] do
15+
source_branch = 'source'
16+
deploy_branch = 'gh-pages'
17+
message = "Site updated at #{Time.now.utc}"
18+
19+
puts "...git pull origin \"#{source_branch}\""
20+
system "git pull origin \"#{source_branch}\""
21+
puts "...update plot schema"
22+
system "curl https://api.plot.ly/v2/plot-schema?sha1=%27%27 > _data/plotschema.json && git add _data/plotschema.json && git commit -m \"Updated plotschema at #{Time.now.utc}\" && git push origin \"#{source_branch}\""
23+
puts "...generate _site"
24+
system "jekyll build && git checkout \"#{deploy_branch}\" && git pull origin \"#{deploy_branch}\" && cp -r _site/* . && rm -rf _site/ && touch .nojekyll && git add . && git commit -m \"#{message}\" && git push origin \"#{deploy_branch}\""
25+
puts "...git checkout \"#{source_branch}\""
26+
system "git checkout \"#{source_branch}\""
27+
system "osascript -e 'display notification \"rake deploy just finished\" with title \"Docs are ready!\"'"
28+
end

_config_dev.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@
33
- jekyll-sitemap
44
# - jemoji
55

6-
BASE_URL: http://localhost:3000
7-
staticurl: http://localhost:3000/all_static
8-
# all of the posts: ['*.Rmd','_posts/2015-09-09-matlab-reference.html','_posts/2015-09-06-r-reference.html','_posts/2015-09-06-python-reference.html','_posts/2015-08-19-plotly_js-reference.html','_posts/2015-04-05-ggplot2-index.html','_posts/2015-04-05-julia-index.html','_posts/2015-04-05-matlab-index.html','_posts/2015-04-05-matplotlib-index.html','_posts/2015-04-05-node_js-index.html','_posts/2015-04-05-plotly_js-index.html','_posts/2015-04-05-plotlyjs-function-reference.md','_posts/2015-04-05-python-index.html','_posts/2015-05-25-ipython-notebooks_gallery.html','_posts/2015-05-25-ipython-notebooks_index.html','_posts/2015-07-13-eula_index.html','_posts/2015-07-19-pandas.html','_posts/2015-07-26-index.html','_posts/2015-07-30-r-index.Rmd','_posts/2015-07-30-r-index.md','_posts/2015-08-20-research-box-index.html','_posts/ggplot2','_posts/julia','_posts/matlab','_posts/matplotlib','_posts/nodejs','_posts/pandas','_posts/plotly_js','_posts/python','_posts/r','_posts/tutorials','_posts/user_guide_matlab','_posts/user_guide_python']
9-
# exclude: ['*.Rmd','_posts/2015-09-09-matlab-reference.html','_posts/2015-09-06-r-reference.html','_posts/2015-09-06-python-reference.html','_posts/2015-08-19-plotly_js-reference.html','_posts/2015-04-05-ggplot2-index.html','_posts/2015-04-05-julia-index.html','_posts/2015-04-05-matplotlib-index.html','_posts/2015-04-05-node_js-index.html','_posts/2015-04-05-plotly_js-index.html','_posts/2015-04-05-plotlyjs-function-reference.md','_posts/2015-04-05-python-index.html','_posts/2015-05-25-ipython-notebooks_gallery.html','_posts/2015-05-25-ipython-notebooks_index.html','_posts/2015-07-13-eula_index.html','_posts/2015-07-19-pandas.html','_posts/2015-07-26-index.html','_posts/2015-07-30-r-index.Rmd','_posts/2015-07-30-r-index.md','_posts/2015-08-20-research-box-index.html','_posts/ggplot2','_posts/julia','_posts/matplotlib','_posts/nodejs','_posts/pandas','_posts/plotly_js','_posts/python','_posts/r','_posts/tutorials','_posts/user_guide_python']
106

11-
exclude: [ _posts/r, _posts/matlab, _posts/matplotlib, _posts/nodejs, _posts/ggplot2, _posts/julia] # [ _posts/python]
7+
BASE_URL: http://localhost:4000
8+
staticurl: http://localhost:4000/all_static
9+
# all of the posts: ['*.Rmd','_posts/2015-09-09-matlab-reference.html','_posts/2015-09-06-r-reference.html','_posts/2015-09-06-python-reference.html','_posts/2015-08-19-plotly_js-reference.html','_posts/2015-04-05-ggplot2-index.html','_posts/2015-04-05-julia-index.html','_posts/2015-04-05-matlab-index.html','_posts/2015-04-05-matplotlib-index.html','_posts/2015-04-05-node_js-index.html','_posts/2015-04-05-plotly_js-index.html','_posts/2015-04-05-plotlyjs-function-reference.md','_posts/2015-04-05-python-index.html','_posts/2015-05-25-ipython-notebooks_gallery.html','_posts/2015-05-25-ipython-notebooks_index.html','_posts/2015-07-13-eula_index.html','_posts/2015-07-19-pandas.html','_posts/2015-07-26-index.html','_posts/2015-07-30-r-index.Rmd','_posts/2015-07-30-r-index.md','_posts/2015-08-20-research-box-index.html','_posts/ggplot2','_posts/julia','_posts/matlab','_posts/matplotlib','_posts/nodejs','_posts/pandas','_posts/plotly_js','_posts/python','_posts/r','_posts/tutorials','_posts/user_guide_matlab','_posts/user_guide_python']
10+
exclude: ['*.Rmd','_posts/2015-09-09-matlab-reference.html','_posts/2015-09-06-r-reference.html','_posts/2015-09-06-python-reference.html','_posts/2015-08-19-plotly_js-reference.html','_posts/2015-04-05-ggplot2-index.html','_posts/2015-04-05-julia-index.html','_posts/2015-04-05-matplotlib-index.html','_posts/2015-04-05-node_js-index.html','_posts/2015-04-05-plotly_js-index.html','_posts/2015-04-05-plotlyjs-function-reference.md','_posts/2015-04-05-python-index.html','_posts/2015-05-25-ipython-notebooks_gallery.html','_posts/2015-05-25-ipython-notebooks_index.html','_posts/2015-07-13-eula_index.html','_posts/2015-07-19-pandas.html','_posts/2015-07-26-index.html','_posts/2015-07-30-r-index.Rmd','_posts/2015-07-30-r-index.md','_posts/2015-08-20-research-box-index.html','_posts/ggplot2','_posts/julia','_posts/matplotlib','_posts/nodejs','_posts/pandas','_posts/plotly_js','_posts/python','_posts/r','_posts/tutorials','_posts/user_guide_python']
11+
plotlyjs_download_url: https://cdn.plot.ly/plotly-latest.min.js
12+
imgurl: https://images.plot.ly/plotly-documentation/
1213

1314

1415
plotlyjs_download_url: https://cdn.plot.ly/plotly-latest.min.js

_data/plotschema.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

_includes/_new/_page-components/_footer-main.html

Lines changed: 165 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,3 +128,168 @@ <h6 class="--footer-heading">Connect</h6>&#x9;&#x9;&#x9;
128128
</footer>
129129
<script src="//images.plot.ly/assets/js/ZeroClipboard.min.js"></script>
130130
<script src="//images.plot.ly/assets/js/main.js"></script>
131+
132+
{% if page.layout == "user-guide" %}
133+
<!-- Mathjax -->
134+
<script type='text/x-mathjax-config'>
135+
MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']], processEscapes: true}});
136+
137+
</script>
138+
<script type='text/javascript'
139+
src='//cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML%2CSafe.js&#038;ver=4.1'></script>
140+
{% endif %}
141+
142+
<!-- Image Hover Script -->
143+
<script src="{{site.staticurl}}/javascripts/imghover.js"></script>
144+
145+
<!-- code highlighting -->
146+
<script src="{{site.staticurl}}/javascripts/codehighlight/highlight.pack.js"></script>
147+
<script>hljs.initHighlightingOnLoad();</script>
148+
149+
<!-- Google Analytics -->
150+
<script>
151+
(function (i, s, o, g, r, a, m) {
152+
i['GoogleAnalyticsObject'] = r;
153+
i[r] = i[r] || function () {
154+
(i[r].q = i[r].q || []).push(arguments)
155+
}, i[r].l = 1 * new Date();
156+
a = s.createElement(o),
157+
m = s.getElementsByTagName(o)[0];
158+
a.async = 1;
159+
a.src = g;
160+
m.parentNode.insertBefore(a, m)
161+
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
162+
ga('create', 'UA-39373211-1', 'auto');
163+
ga('send', 'pageview');
164+
</script>
165+
166+
<!-- start Mixpanel -->
167+
<script type="text/javascript">(function (e, b) {
168+
if (!b.__SV) {
169+
var a, f, i, g;
170+
window.mixpanel = b;
171+
b._i = [];
172+
b.init = function (a, e, d) {
173+
function f(b, h) {
174+
var a = h.split(".");
175+
2 == a.length && (b = b[a[0]], h = a[1]);
176+
b[h] = function () {
177+
b.push([h].concat(Array.prototype.slice.call(arguments, 0)))
178+
}
179+
}
180+
181+
var c = b;
182+
"undefined" !== typeof d ? c = b[d] = [] : d = "mixpanel";
183+
c.people = c.people || [];
184+
c.toString = function (b) {
185+
var a = "mixpanel";
186+
"mixpanel" !== d && (a += "." + d);
187+
b || (a += " (stub)");
188+
return a
189+
};
190+
c.people.toString = function () {
191+
return c.toString(1) + ".people (stub)"
192+
};
193+
i = "disable time_event track track_pageview track_links track_forms register register_once alias unregister identify name_tag set_config people.set people.set_once people.increment people.append people.union people.track_charge people.clear_charges people.delete_user".split(" ");
194+
for (g = 0; g < i.length; g++)f(c, i[g]);
195+
b._i.push([a, e, d])
196+
};
197+
b.__SV = 1.2;
198+
a = e.createElement("script");
199+
a.type = "text/javascript";
200+
a.async = !0;
201+
a.src = "undefined" !== typeof MIXPANEL_CUSTOM_LIB_URL ? MIXPANEL_CUSTOM_LIB_URL : "file:" === e.location.protocol && "//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js".match(/^\/\//) ? "https://cdn.mxpnl.com/libs/mixpanel-2-latest.min.js" : "//cdn.mxpnl.com/libs/mixpanel-2-latest.min.js";
202+
f = e.getElementsByTagName("script")[0];
203+
f.parentNode.insertBefore(a, f)
204+
}
205+
})(document, window.mixpanel || []);
206+
mixpanel.init("ad6df61d0b9400400b240631576c24d4");</script><!-- end Mixpanel -->
207+
208+
<script type="text/javascript">
209+
mixpanel.track("Page visit", {
210+
"url_group": "API docs - GitHub pages",
211+
"url": window.location.pathname
212+
});
213+
</script>
214+
215+
<script type="text/javascript">
216+
function getQueryParam(param) {
217+
param = param.replace(/[\[]/, "\\\[").replace(/[\]]/, "\\\]");
218+
var regexS = "[\\?&]" + param + "=([^&#]*)",
219+
regex = new RegExp(regexS),
220+
results = regex.exec(document.URL);
221+
if (results === null || (results && typeof(results[1]) !== 'string' && results[1].length)) {
222+
return '';
223+
} else {
224+
return decodeURIComponent(results[1]).replace(/\+/g, ' ');
225+
}
226+
}
227+
;
228+
</script>
229+
230+
<script type="text/javascript">
231+
var visit_origin = getQueryParam("campaign_id");
232+
233+
mixpanel.register({
234+
"email_campaign_received": visit_origin
235+
});
236+
237+
mixpanel.track("email-campaign-visit", {
238+
"url": window.location.pathname,
239+
"email_campaign_received": visit_origin
240+
});
241+
</script>
242+
243+
244+
<!-- Crazy Egg -->
245+
<script type="text/javascript">
246+
setTimeout(function () {
247+
var a = document.createElement("script");
248+
var b = document.getElementsByTagName("script")[0];
249+
a.src = document.location.protocol + "//script.crazyegg.com/pages/scripts/0042/1249.js?" + Math.floor(new Date().getTime() / 3600000);
250+
a.async = true;
251+
a.type = "text/javascript";
252+
b.parentNode.insertBefore(a, b)
253+
}, 1);
254+
</script>
255+
256+
<!-- Go to www.addthis.com/dashboard to customize your tools -->
257+
<script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=ra-563d60eba90f0f45"
258+
async="async"></script>
259+
260+
<!-- Intercom.io for R and Python pages -->
261+
{% if page.language == "r" or page.language == "python" %}
262+
<script>window.intercomSettings = {app_id: "anwi88es"};</script>
263+
<script>(function () {
264+
var w = window;
265+
var ic = w.Intercom;
266+
if (typeof ic === "function") {
267+
ic('reattach_activator');
268+
ic('update', intercomSettings);
269+
} else {
270+
var d = document;
271+
var i = function () {
272+
i.c(arguments)
273+
};
274+
i.q = [];
275+
i.c = function (args) {
276+
i.q.push(args)
277+
};
278+
w.Intercom = i;
279+
function l() {
280+
var s = d.createElement('script');
281+
s.type = 'text/javascript';
282+
s.async = true;
283+
s.src = 'https://widget.intercom.io/widget/anwi88es';
284+
var x = d.getElementsByTagName('script')[0];
285+
x.parentNode.insertBefore(s, x);
286+
}
287+
288+
if (w.attachEvent) {
289+
w.attachEvent('onload', l);
290+
} else {
291+
w.addEventListener('load', l, false);
292+
}
293+
}
294+
})()</script>
295+
{% endif %}

_includes/documentation_eg.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -981,4 +981,4 @@
981981

982982

983983
{% endif %}
984-
{% endif %}
984+
{% endif %}

_includes/footer.html

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<footer>
2-
<div class="plotly-footer">
2+
<div class="plotly-footer" id="footer">
33
{% include plotly_offline_cta.html %}
44
<div class="row footerarea footer-top" style="z-index: 100; position: relative;">
55
<div class="one column footcolumn space"> </div>
@@ -138,15 +138,8 @@ <h6 class="footer-heading">Connect</h6>
138138
<!-- Go to www.addthis.com/dashboard to customize your tools -->
139139
<script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=ra-563d60eba90f0f45" async="async"></script>
140140

141-
<!-- Perfect Audience -->
142-
<script type="text/javascript">
143-
(function() {
144-
window._pa = window._pa || {};
145-
// _pa.orderId = "myOrderId"; // OPTIONAL: attach unique conversion identifier to conversions
146-
// _pa.revenue = "19.99"; // OPTIONAL: attach dynamic purchase values to conversions
147-
// _pa.productId = "myProductId"; // OPTIONAL: Include product ID for use with dynamic ads
148-
var pa = document.createElement('script'); pa.type = 'text/javascript'; pa.async = true;
149-
pa.src = ('https:' == document.location.protocol ? 'https:' : 'http:') + "//tag.marinsm.com/serve/5641f73b04b7cacb9d000124.js";
150-
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(pa, s);
151-
})();
152-
</script>
141+
<!-- Intercom.io for R and Python pages -->
142+
{% if page.language == "r" or page.language == "python" %}
143+
<script>window.intercomSettings = { app_id: "anwi88es" };</script>
144+
<script>(function(){var w=window;var ic=w.Intercom;if(typeof ic==="function"){ic('reattach_activator');ic('update',intercomSettings);}else{var d=document;var i=function(){i.c(arguments)};i.q=[];i.c=function(args){i.q.push(args)};w.Intercom=i;function l(){var s=d.createElement('script');s.type='text/javascript';s.async=true;s.src='https://widget.intercom.io/widget/anwi88es';var x=d.getElementsByTagName('script')[0];x.parentNode.insertBefore(s,x);}if(w.attachEvent){w.attachEvent('onload',l);}else{w.addEventListener('load',l,false);}}})()</script>
145+
{% endif %}

_includes/head.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,5 +42,4 @@
4242
crossorigin="anonymous"></script>
4343

4444

45-
</head>
46-
45+
</head>

0 commit comments

Comments
 (0)