Re: [sage-devel] Jupyter notebook by default?

2016-09-10 Thread kcrisman


On Friday, September 9, 2016 at 6:51:00 PM UTC-4, Jason Grout wrote:
>
> Nice! That's even better that it works out-of-the-box!
>
>>
>>
+1

Yes, that is great that the same hooks work in Jupyter for this - and 
thanks Samuel for using this to answer the original post.  

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-09-09 Thread Jason Grout
Nice! That's even better that it works out-of-the-box!

Jason


On Fri, Sep 9, 2016 at 6:06 PM Volker Braun  wrote:

>
> 
>
>
> On Friday, September 9, 2016 at 2:53:29 PM UTC+2, kcrisman wrote:
>>
>> Sorry for the necropost, but I couldn't find any other canonical place to
>> mention this:
>>
>> https://ask.sagemath.org/question/34782/how-to-render-html-or-latex-tables-in-jupyter-notebook/
>> Likely this is a fairly easy hook thing or the pretty_print issue but
>> thought it should be here for completeness.
>>
> --
> You received this message because you are subscribed to the Google Groups
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-devel+unsubscr...@googlegroups.com.
> To post to this group, send email to sage-devel@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-09-09 Thread Volker Braun





On Friday, September 9, 2016 at 2:53:29 PM UTC+2, kcrisman wrote:
>
> Sorry for the necropost, but I couldn't find any other canonical place to 
> mention this:
>
> https://ask.sagemath.org/question/34782/how-to-render-html-or-latex-tables-in-jupyter-notebook/
> Likely this is a fairly easy hook thing or the pretty_print issue but 
> thought it should be here for completeness.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-09-09 Thread kcrisman


> A bit more robust in escaping:
>
>>
>>>
Thanks.  I don't know enough about the Jupyter nb to know whether there is 
an easy way to get it to render HTML output - perhaps %%html , which would 
seem to me to be what is asked for but I don't use it myself.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-09-09 Thread Jason Grout
A bit more robust in escaping:

try:
from html import escape  # python 3.x
except ImportError:
from cgi import escape  # python 2.x
from IPython.display import HTML

def table(data):
rows = [["%s"%escape(str(i)) for i in data[0]]]
rows.extend([["%s"%escape(str(i)) for i in row] for row in
data[1:]])
s = '\n'.join(['%s'%(''.join(row)) for row in rows])
return HTML('%s'%s)

table([('Header 1', 'Header 2'), (1,'<'), (3,4)])

On Fri, Sep 9, 2016 at 9:28 AM Jason Grout  wrote:

> I don't think we have a good table-printing function built into IPython. A
> simple one is probably pretty straightforward:
>
> try:
> from html import escape  # python 3.x
> except ImportError:
> from cgi import escape  # python 2.x
> from IPython.display import HTML
>
> def table(data):
> rows = [["%s"%escape(i) for i in data[0]]]
> rows.extend([["%s"%i for i in row] for row in data[1:]])
> s = '\n'.join(['%s'%(''.join(row)) for row in rows])
> return HTML('%s'%s)
>
> table([('Header 1', 'Header 2'), (1,2), (3,4)])
>
>
> On Fri, Sep 9, 2016 at 8:53 AM kcrisman  wrote:
>
>> Sorry for the necropost, but I couldn't find any other canonical place to
>> mention this:
>>
>> https://ask.sagemath.org/question/34782/how-to-render-html-or-latex-tables-in-jupyter-notebook/
>> Likely this is a fairly easy hook thing or the pretty_print issue but
>> thought it should be here for completeness.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "sage-devel" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to sage-devel+unsubscr...@googlegroups.com.
>> To post to this group, send email to sage-devel@googlegroups.com.
>> Visit this group at https://groups.google.com/group/sage-devel.
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-09-09 Thread Jason Grout
I don't think we have a good table-printing function built into IPython. A
simple one is probably pretty straightforward:

try:
from html import escape  # python 3.x
except ImportError:
from cgi import escape  # python 2.x
from IPython.display import HTML

def table(data):
rows = [["%s"%escape(i) for i in data[0]]]
rows.extend([["%s"%i for i in row] for row in data[1:]])
s = '\n'.join(['%s'%(''.join(row)) for row in rows])
return HTML('%s'%s)

table([('Header 1', 'Header 2'), (1,2), (3,4)])


On Fri, Sep 9, 2016 at 8:53 AM kcrisman  wrote:

> Sorry for the necropost, but I couldn't find any other canonical place to
> mention this:
>
> https://ask.sagemath.org/question/34782/how-to-render-html-or-latex-tables-in-jupyter-notebook/
> Likely this is a fairly easy hook thing or the pretty_print issue but
> thought it should be here for completeness.
>
> --
> You received this message because you are subscribed to the Google Groups
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-devel+unsubscr...@googlegroups.com.
> To post to this group, send email to sage-devel@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-09-09 Thread kcrisman
Sorry for the necropost, but I couldn't find any other canonical place to 
mention this:
https://ask.sagemath.org/question/34782/how-to-render-html-or-latex-tables-in-jupyter-notebook/
Likely this is a fairly easy hook thing or the pretty_print issue but 
thought it should be here for completeness.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-01-27 Thread kcrisman


>
> I surprisingly don't remember even one user request for such 
> tinymce style wysiwyg editing for SMC.  And our users are constantly asking 
> for the functionality they feel they really need...  I'm very surprised by 
> this lack of demand. However maybe they don't know what they want. 
>
>
>
Well, I think that as always there are two groups of people interested in 
feature X.

1) People who can't do without it but see right away it's not possible, and 
aren't invested enough to ask and so just don't use it (whatever "it" is, 
not just SMC).
2) People who figure the advantages of "it" are good enough that it's okay 
to deal without it.

Group 3 is of course the ones who ask you, but perhaps whoever is using SMC 
doesn't need it/want it enough to ask.  It would be interesting to see how 
technically advanced the typical SMC user perceives themselves.

[My guess (and only a guess) is that anyone who wants a "real" wysiwyg for 
this is too intimidated by the interface to use it much anyway, assuming 
they even look into it.  But that may change as more people are introduced 
to SMC, and/or my guess may be wrong.]

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-01-26 Thread William Stein
On Tuesday, January 26, 2016, kcrisman  wrote:

>
>
>>
>> For what it is worth, SageMathCloud has a buttons/lists, etc. for
>> editing markdown in Sage worksheets, and also a realtime preview
>> markdown editor for md files.  Two screenshots attached.  I also fully
>> implemented a realtime WYSIWYG editor for html and markdown a year
>> ago, but decided it wasn't up to my standards (getting realtime sync
>> to fully work well was surprisingly challenging), so I
>> disabled/removed it.
>>
>
> Oh yeah, I forgot that I get very confused trying to make text cells in
> SMC too :(  presumably for the same reason that I don't want to type %md -
> but I don't use SMC much (yet).  I'm surprised that there isn't more stuff
> out there trying to do fully-featured wysiwyg md editing, actually,
> obviously it is completely orthogonal to the math and of very general
> interest.  Huh.
>

I surprisingly don't remember even one user request for such
tinymce style wysiwyg editing for SMC.  And our users are constantly asking
for the functionality they feel they really need...  I'm very surprised by
this lack of demand. However maybe they don't know what they want.



>
>>
>>
>> --
> You received this message because you are subscribed to the Google Groups
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-devel+unsubscr...@googlegroups.com
> 
> .
> To post to this group, send email to sage-devel@googlegroups.com
> .
> Visit this group at https://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.
>


-- 
Sent from my massive iPhone 6 plus.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-devel] Jupyter notebook by default?

2016-01-02 Thread William Stein
On Saturday, January 2, 2016, Volker Braun  wrote:

> You still haven't understood that this is about how to create new
> notebooks. We have the legacy support covered by shipping the old notebook.
> Also, I don't recall Microsoft bundling a free copy of word 2007 with word
> 2010, you are comparing apples and oranges.
>
> On Friday, January 1, 2016 at 4:01:18 PM UTC+1, kcrisman wrote:
>>
>> How many of those zillions of easy-to-search sample worksheets are about
>> something like calculating elliptic curve invariants or a nice demo for a
>> graph theory course?
>>
>
> And maybe we have the market for EC invariants saturated, and the reason
> for not growing any more is that we don't fit into the larger scientific
> Python ecosystem?
>

+1000!



>
> --
> You received this message because you are subscribed to the Google Groups
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-devel+unsubscr...@googlegroups.com
> 
> .
> To post to this group, send email to sage-devel@googlegroups.com
> .
> Visit this group at https://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.
>


-- 
Sent from my massive iPhone 6 plus.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.


[sage-devel] Jupyter notebook by default?

2015-12-18 Thread Jeroen Demeyer
Should the Jupyter notebook be the default notebook for the next Sage 
7.0 release? I don't really have an opinion on the matter.



Pros:

* Nice tracebacks!
* The Jupyter notebook is a mature well-maintained project, unlike 
SageNB. It is widely used in the "scientific Python" community.

* Availability of other Jupyter kernels besides Sage.


Cons:

* Less compatible with Sage: Sage interacts don't work, some graphics 
don't work.
* Certain features of SageNB are missing: live documentation, 
sharing/publishing of worksheets.

* It clutters the file system with .ipynb files.


Don't cares:

* It's just a default choice, both options remain available.

--
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.