ASKSAGE: Sage Q&A Forum - Latest question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Thu, 28 Dec 2017 04:59:31 -0600Cell label resethttp://ask.sagemath.org/question/40336/cell-label-reset/What is the proper way to reset the cell number in a notebook cell?
When I evaluate all the cells of a notebook I want to always start with the number In[1] as the first cell label of the notebook in order to have a predictable number of all the subsequent cells, something like kill(labels) in Maxima.
danielvolinskiThu, 28 Dec 2017 04:59:31 -0600http://ask.sagemath.org/question/40336/previous fontsize settings in plot now produce huge fontshttp://ask.sagemath.org/question/29464/previous-fontsize-settings-in-plot-now-produce-huge-fonts/I have been using p.fontsize(20) a lot, but since the upgrade to 6.8, the same setting now produces HUGE font sizes, making the axes labels exceed the figure sizes. I wonder what happened there and how this could be fixed.
I believe that some of the reason is the introduction of the new option axes_labels_size as mentioned here:
http://ask.sagemath.org/question/26807/how-do-i-adjust-the-size-of-axes-labels-and-figure-titles-in-plots/
Try this in a sage version before 6.7 and after 6.7:
P = plot(x^2, 0,2)
P.axes_labels(['Some value of x', 'Resulting value of y'])
P.fontsize(20)
P
Is there a way to put a one-liner at the start of my worksheets to get back the old behaviour without having to modify all P.fontsize(20) lines?
stanWed, 16 Sep 2015 07:57:35 -0500http://ask.sagemath.org/question/29464/Size of Labels on a Plothttp://ask.sagemath.org/question/7518/size-of-labels-on-a-plot/dear all:
I'd like to know if there is any way to change the size of the font of labels (in a plot) without changing the size of the numbers on the ticks.
Thank youDoxMon, 08 Apr 2013 06:42:04 -0500http://ask.sagemath.org/question/7518/How to add string tick labels to 2D plots?http://ask.sagemath.org/question/9945/how-to-add-string-tick-labels-to-2d-plots/Hi folks, i want to add string tick labels to a 2D plot, e.g. `['$100', '$200', '$300']` on the x-axis instead of the ticks `[1, 2, 3]`. I see from [http://stackoverflow.com/questions/5439708/python-matplotlib-creating-date-ticks-from-string](http://stackoverflow.com/questions/5439708/python-matplotlib-creating-date-ticks-from-string) that i can do this with matplotlib via
from matplotlib import pyplot as plt
plt.plot([1,2,3],[3,4,3])
ax = plt.gca()
ax.set_xticks([1,2,3])
ax.set_xticklabels(['$100','$200','$300'])
Is there a Sage way to accomplish the same thing?
Personally, i find Sage plotting commands more user-friendly than matplotlib commands.araichevSun, 24 Mar 2013 12:48:21 -0500http://ask.sagemath.org/question/9945/2d plot axes labelshttp://ask.sagemath.org/question/9235/2d-plot-axes-labels/Hello,
How do I add labels (names) to my axes when doing a simple 2d plot such as:
t = var('t')
E(t)=(10.40*(1-exp(-0.25*t)))^2.81
plot(E,t,(x,0,15))
I would like to do so the labels are aligned directly under the x axis and vertically over the y axis. Is there a way?brenogilTue, 14 Aug 2012 08:20:31 -0500http://ask.sagemath.org/question/9235/2 Plotting Questionshttp://ask.sagemath.org/question/7851/2-plotting-questions/I have been able to get most things working with:
list_plot([(r,Pabrf(Ratio=r).n()) for r in srange(-1, 1, 0.1, include_endpoint=True)], plotjoined=True, frame=true, ymin=0,axes_labels=('$\Omega _{0}/\omega _{nut}$',"$ P _{a\rightarrow b}$"),ticks=[[-1, -0.5,0,0.5,1],[0.2,0.4,0.6,0.8,1.0]])
I have an additional questions about controlling plot features:
1. How do I turn off or turn on the lines at the origin(0)? I can find nothing in the Matplotlib docs that mentions this.
2. How do I get the \rightarrow to display instead of the \Rightarrow? The \Rightarrow, \dashrightarrow and \longrightarrow display properly, I think this a bug.
Thank you again for your help.mhfreyFri, 07 Jan 2011 03:44:15 -0600http://ask.sagemath.org/question/7851/