« first day (3166 days earlier)      last day (1475 days later) » 

12:11 AM
sometimes I think SO regrets the SE sites and is trying to kill them by not supporting them...
meta.stackexchange.com/a/353990/463832 this meta answer definitely deserving of upvotes. if SO commit to rolling out new versions of syntax highlighting on a regular basis then that would be a huge upgrade for us (new symbols need highlighting and it certainly seemed like a big hassle to get that done before...)
Strangely from that it seems like the keywords should be being highlighted and are not, which doesn't fill me with enormous confidence
 
3 hours later…
2:47 AM
@CarlLange if you look at the official demo, too, it looks like they're missing highlighting for # and stuff (and that's even in their demo example!) highlightjs.org/static/demo
3:26 AM
If I take a look at what they seem to be calling that code, it thinks the first is delphi and the second is rust. It doesn't matter if I use Mathematica, mathematica, mma, or wl, though, so clearly if highlight.js gets a language name it doesn't understand, it just tries to infer a different one
Here's an annoying thing I didn't know about. Using a block like this doesn't specify a language on SE
```mathematica
...
```
instead you need to use lang-mathematica for it to use it
but their version of highlight.js doesn't support Mathematica, which I found by checking the actual JS they served me, which has a bunch of blocks like some.obj.registerLanguage("...", ...) but neither Mathematica, mma, nor wl are in those keywords, despite the fact that Mathematica has been in the highlight.js GitHub source for over a year
When hightlight.js hits us in like a week, we'll probably need to make a fuss on Meta about it...
This seems to be their served thing, btw: cdn.sstatic.net/Js/highlightjs-loader.en.js
4:06 AM
0
A: Goodbye, Prettify. Hello highlight.js! Swapping out our Syntax Highlighter

b3m2a1What to do if highlight.js supports a language but Stack Exchange doesn't? There's an entire Mathematica StackExchange, and so Mathematica syntax highlight is clearly very important to us. But when I did some digging to find the highlight.js bundle that SE seems to be serving, Mathematica isn't i...

 
7 hours later…
11:20 AM
@b3m2a1 Yeah, that's unfortunate. But at least we should be able to extend it without too much hassle given the codebase.
I wonder if that ```lang thing is going to change when they change the markdown parser, which I thought I read about a while ago
 
5 hours later…
4:30 PM
@CarlLange it doesn't seem to have changed, even though I think Meta StackExchange is already on CommonMark
4:45 PM
ResourceFunction["SimulateAnimalVision"]["Human:Deuteranopia", img] makes you doubt the usefulness of the resource function repo....It would be nice to have a filter to test for color-blind friendliness in Mathematica.
@b3m2a1 Good point. What a pity.
@MichaelE2 It seems somewhat closer to accurate if you do "SetFinalBackgroundWhiteQ"->True
5:20 PM
@CarlLange Thanks. I'm not an expert on colorblindness, and what I think I know is built from consistency in what I find on the web, esp. from organizations dedicated to it or to accessibility. While some results of the resource function are closer , some seem farther away. Sometimes I wonder whether what I think I know is flawed.
 
2 hours later…
6:59 PM
@MichaelE2 Yeah, I know very little about it myself but I find it mildly odd that the method used in the resource function is simply to remove an rgb component
@CarlLange Exactly.
Although I do accept that for animals I can definitely live with a no-nuance, "roughly-this" answer
I'm sad not to see a citation since the values given for animals are exact and I'm curious where they came from
@CarlLange Yeah. In my case, I'm interested in making teaching materials that are accessible to actual color-blind students, so there's a real benefit to doing it right.
I haven't had much cause to use it but I have been pretty interested in WL's color theory functionality, so I'm pretty sure it's possible to create a reasonably sophisticated model with just the built-ins
Given this image, it's pretty clear that just removing an rgb component isn't gonna do it en.wikipedia.org/wiki/File:Color_blindness.png
There's a nonexpert like me on Community who did something (community.wolfram.com/groups/-/m/t/1278303). It's much closer than the resource function, but not in complete agreement. Well, even some of the reference filters I used for comparison don't agree perfectly.
7:10 PM
There's an R package with attached paper that seems (after a quick skim) to know what it's talking about onlinelibrary.wiley.com/doi/full/10.1002/ece3.4288
That community post is quite nice.
I'm finally switching from Mac to Pop!_OS (and getting a nice 12-core processor in the deal). I'm a bit nervous that the Mathematica experience is going to be much worse on Linux since SW doesn't seem to ever use Linux (and that's how you know it'll work OK, of course)
I guess that's not true, I've seen him run remote kernels that are definitely on Linux. I'm more worried about the frontend
@CarlLange Thanks for the ref.
7:27 PM
@MichaelE2 Not a problem and I applaud your intention to make sure that coursework is accessible to all of your students!
8:11 PM
has anyone had a need for a AssociationSelect (like AssociationMap) to wrap up the idiom Association[Select[Normal[assoc1], test1[#[[1]]] && test2[#[[2]]] &]] ?
8:31 PM
@Manuel--Moe--G Could do Select[test2]@KeySelect[test1]@assoc1
8:43 PM
assoc1=<|"cathat1"->5,"doghat1"->-5,"cat2"->-6,"dog2"->6|>;
Association[Select[Normal@assoc1,StringContainsQ[#[[1]],"hat"]&&#[[2]]<0&]]
(* <|doghat1->-5|> *)
Select[#<0&]@KeySelect[StringContainsQ[#,"hat"]&]@assoc1
(* <|doghat1->-5|> *)
well, how about that!
thanks!
 
1 hour later…
10:06 PM
@b3m2a1 Great question! That comment about the size increasing by 75 % by including Mathematica highlighting is pretty interesting...
10:29 PM
@C.E. Yeah, the mathematica file is 95KB uncompressed, so that about holds up. It's basically just a big ol list of symbols so I wonder just how much it could be improved by

« first day (3166 days earlier)      last day (1475 days later) »