<div dir="ltr">Just as a heads up, I implemented this in <a href="https://github.com/astropy/astropy/pull/4052">https://github.com/astropy/astropy/pull/4052</a> (I've had to do something similar so DataTables would sort numbers in scientific notation).<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 5, 2015 at 12:23 PM, Erik Bray <span dir="ltr"><<a href="mailto:embray@stsci.edu" target="_blank">embray@stsci.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 08/05/2015 12:16 PM, Leonard Burtscher wrote:<br>
> Thanks, Adam and Erik, for your quick answers and sorry for not checking the<br>
> bugtracker before. I won't get to this within the next week or so, but then I<br>
> might try to fix it.<br>
<br>
</span>Much appreciated if you're able!<br>
<br>
Thanks,<br>
Erik<br>
<div class="HOEnZb"><div class="h5"><br>
>> Am 05.08.2015 um 17:06 schrieb Erik Bray <<a href="mailto:embray@stsci.edu">embray@stsci.edu</a>>:<br>
>><br>
>> On 08/05/2015 10:48 AM, Adam Ginsburg wrote:<br>
>>> Hi Leonard, This is something that can be solved within astropy.  There<br>
>>> is an open issue that will probably solve this:<br>
>>> <a href="https://github.com/astropy/astropy/issues/2966" rel="noreferrer" target="_blank">https://github.com/astropy/astropy/issues/2966</a> in case you want to try to<br>
>>> tackle it based on Tom Robitaille's example.<br>
>><br>
>> Indeed, some of the columns you'll notice do sort correctly numerically,<br>
>> like the "z" column in your table.  It's just when columns contain<br>
>> non-numbers like NaN.<br>
>><br>
>> Looks like a reasonably easy pull request since Tom already showed how to<br>
>> approach it (just need to add a custom sort method to dataTable in the<br>
>> javascript), if anyone has been looking for a contribution to make to<br>
>> Astropy...<br>
>><br>
>> Erik<br>
>><br>
>>> On Wed, Aug 5, 2015 at 4:31 PM, Leonard Burtscher <<a href="mailto:burtscher@mpe.mpg.de">burtscher@mpe.mpg.de</a>><br>
>>> wrote:<br>
>>>> Hi,<br>
>>>><br>
>>>> The "show_in_browser" feature for Table is really great, especially<br>
>>>> when combined with jsviewer=True, e.g.<br>
>>>><br>
>>>> <a href="http://www.mpe.mpg.de/~burtscher/APEX/table.html" rel="noreferrer" target="_blank">http://www.mpe.mpg.de/~burtscher/APEX/table.html</a><br>
>>>><br>
>>>> By clicking on the header row, one can sort by that column. However,<br>
>>>> numbers are not sorted correctly, with "9" being before "10" etc. (e.g.<br>
>>>> click on one of the "exptime" columns and look at the bottom of the<br>
>>>> table).<br>
>>>><br>
>>>> Is that something that could be solved within astropy or is it a<br>
>>>> Javascript issue?<br>
>>>><br>
>>>> -- Leo<br>
>>>><br>
>>>> _______________________________________________ AstroPy mailing list<br>
>>>> <a href="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a> <a href="http://mail.scipy.org/mailman/listinfo/astropy" rel="noreferrer" target="_blank">http://mail.scipy.org/mailman/listinfo/astropy</a><br>
>>><br>
>>><br>
>>><br>
>><br>
>> _______________________________________________ AstroPy mailing list<br>
>> <a href="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a> <a href="http://mail.scipy.org/mailman/listinfo/astropy" rel="noreferrer" target="_blank">http://mail.scipy.org/mailman/listinfo/astropy</a><br>
><br>
> _______________________________________________ AstroPy mailing list<br>
> <a href="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a> <a href="http://mail.scipy.org/mailman/listinfo/astropy" rel="noreferrer" target="_blank">http://mail.scipy.org/mailman/listinfo/astropy</a><br>
><br>
<br>
_______________________________________________<br>
AstroPy mailing list<br>
<a href="mailto:AstroPy@scipy.org">AstroPy@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/astropy" rel="noreferrer" target="_blank">http://mail.scipy.org/mailman/listinfo/astropy</a><br>
</div></div></blockquote></div><br></div>