« first day (1290 days earlier)      last day (3200 days later) » 

2:53 AM
I got tired of him cherry-picking phrases from what I said without reading the whole. So, I called him on it. We'll see if it helps.
@ChrisJJ no, you're deliberately cherry-picking specific phrases and avoiding others, and I can't tell if it is deliberate, or something in your make-up. But, it is a form of dishonesty, and I have been nothing but honest with you. Please re-read what I wrote in its entirety. — rcollyer 18 mins ago
 
 
7 hours later…
9:30 AM
@halirutan Is there any chance the highlighter could be made to recognize greek letters as letter? I know I asked this before but I can't recall the reason why it wasn't possible ... Now we have a tool to easily fix up greek, and many more posts with greek in them than before.
 
@Szabolcs Yes, I hope that should be easily possible. For the IDEA plugin, I only had to change the pattern for identifiers from something like [$0-1A-z] to using a standard :letter: class that contained all possible utf8 letters.
@Szabolcs I guess we need something like the \w class as described here.
Currently, we are simply using
// Literals like variables, non-keyword functions
[PR.PR_PLAIN, /^[a-zA-Z\$][a-zA-Z0-9\$`]*/, null],
 
9:57 AM
@halirutan There is says it also matches _, though ...
Regex is so messy, different engines support different things ...
Doesn't look good:
4
Q: Regular expression to match ASCII and Unicode characters

ThomasRecently I discovered, to my surprise, that JavaScript has no built-in support for Unicode regular expressions. So how can I test a string for characters only, Unicode or ASCII?

> "Recently I discovered, to my surprise, that JavaScript has no built-in support for Unicode regular expressions."
80
Q: Javascript + Unicode regexes

AmitDoes anyone know of any JavaScript libraries that support Unicode-aware regular expressions? For example, there should be something akin to \w that can match any code-point in Letters or Marks category (not just the ASCII ones), and hopefully have filters like [[P*]] for punctuation etc.

 
@Szabolcs @Szabolcs Hmm, there is probably not an solution as easy as for the IDEA lexer. The situation regarding utf8 seems to weird for javascript.
 
All those questions are old, and I don't know what has changed since then. Did browsers adopt ES6 with Unicode regexes since then?
If not, it's not worth the trouble.
 
@Szabolcs One good thing is that google code prettify moved to GitHub. I can easily ask there as an issue. I have no idea whether he uses a specific library. Looking through the code currently..
 
10:32 AM
@halirutan @Szabolcs Hello guys. Is there any topic about function["scope"][arg_] coding style?
 
@Kuba Can you explain in more detail? You can't HoldFirst arg in this case. What are you using it for specifically?
 
@Szabolcs let me try with an example.
 
@Kuba Not sure whether there is a tutorial about it. I mostly use it the way it is used by e.g. InterpolatingFunction where function["scope"] is only some data-structure holding values (and not a function). And then you can write easy access functions using subvalues.
InterpolatingFunction[{{1, 6}}, {5, 3, 0, {6}, {4}, 0, 0, 0, 0, Automatic,
  {}, {}, False}, {{1, 2, 3, 4, 5, 6}}, {{1}, {2}, {3}, {5}, {8}, {5}},
 {Automatic}][3.4]
This is, in general, how it is used for associations and datasets too.
 
userBasePath[path___]:=FileNameJoin[{$UserBaseDrectory, path}]:
initialPath[path___]:=FileNameJoin[{$InitialDrectory, path}];

etc. So I have a set of functions/values that are doing more or less the same thing so I find more readable to write:

path["initial][path___]:=...

than what is above.
I know in this case there are more other ways too.
There are questions though, problem with usage messages, extracting downvalues etc. So is it worth it? etc.
@halirutan Yep, this is how I want to use it but it generates doubts like those above.
@Szabolcs hmm?
 
10:47 AM
@Kuba Basically, you could just try coding it up and when you run into an issue then just ask again.
 
@halirutan That is why I've asked if anyone asked before, I don't want to waste time if there is a feature that may be crucial for my setup :)
@halirutan maybe if usage messages are not a problem, the better way would be: function["scope", arg___]:=...
 
11:20 AM
@Kuba Yeah, and it's hard to guess whether there will be problems in your case.
I can send you a file where I had implemented properties that kind of work like associations and dataset (did this before ass and datasets where included). But I'm not sure whether it is easier to read through my code than just start coding your stuff and see what happens
 
@halirutan I had to start anyway so it's not necessary atm. But thanks. I won't have time to read it now so next time I face this question I will ask you for this file, ok? :)
@halirutan or you can send it anyway if you don't mind :)
 
@Kuba yep, no problem.
have to run now
later
 
@halirutan ok, have a nice day
 
11:48 AM
@Kuba I wouldn't do it without a better reason, because you will lose attributes, usage messages and options. Well, you can use options, but not directly with Options. It might get annoying. In a project I used some "objects" that held some internal state and you could call methods on them, like obj@"method"[params]. The lack of usage messages and the ease of setting/retrieving options with Options got quite annoying in the long term.
That's because I forgot how my package worked and I had to keep referring to some sort of usage message, Options, etc. to remind myself
There are better reasons in many cases though, e.g. think how InterpolatingFunction works, it also requires using SubValues.
There are also cases when I use the fun[params][data] form instead of fun[params, data]. This way it's easy to "make" and store a function with parameters embedded, and use it to transform several data sets.
 
@Szabolcs I think you are right. Thanks for your points.
 
12:48 PM
To high-rep users: It seems the best answer, mathematica.stackexchange.com/questions/67108/…, to the question was deleted by the owner, perhaps due to a misunderstanding. I've edited it and nominated it for undeletion. See what you think, if you're interested.
 
 
1 hour later…
1:57 PM
Hello, I have a function NBSpline[deg_Integer?Positive, idx_Integer?NonNegative, u_] :=
Now I want to add a default value to deg, Namely, deg=0, I define it like this
NBSpline[(deg_Integer?Positive) : 0, idx_Integer?NonNegative, u_] :=
NBSpline[{deg, Range[0, deg + idx + 1]/(deg + 1)}, idx, u]
Syntax::sntxf: "NBSpline[" cannot be followed by "(deg_Integer?Positive):0,idx_Integer?NonNegative,u_]".

Syntax::tsntxi: "(deg_Integer?Positive):0" is incomplete; more input is needed.

Syntax::sntxi: Incomplete expression; more input is needed .
Then I have a another trail as below
NBSpline[deg_Integer?(Positive) : 0, idx_Integer?NonNegative, u_] :=
NBSpline[{deg, Range[0, deg + idx + 1]/(deg + 1)}, idx, u]
 
 
2 hours later…
3:38 PM
I just spend quite a bit of time to carefully write up a question, but then I started to have a strange feeling of deja vu ... so I searched more and finally found the same question asked by someone else ... with an answer written by myself.
I'm having serious memory problems, it seems.
 
Sorry to ask such a question, but where can I find more information about how the p-values shown in mymodel["ParameterTable"] are computed?
 
Hello people
 
4:05 PM
@Sosi If you ask it, I will upvote.
 
@Szabolcs ok ok
 
4:17 PM
@Sosi, linear or nonlinear fitting? They proceed differently, IIRC.
@Szabolcs, that's why I like this site a lot and do my best to write good answers; I can easily imagine my future forgetful self having to search for a particular method only to find my younger self having written a usable solution. ;)
 
4:30 PM
@Guesswhoitis. In a linear model. But the issue is the same (I'm guessing), despite different methods being used: I can't find information on how those p-values are computed. I am guessing a specific distribution is found based on some sampling around the final fitted parameter, and then that distribution is compared to another distribution. But how? What is specifically done?
 
It's using Student-t if memory serves, from my reading of the old Statistics`LinearRegression` package. Does your version still have a "Legacy Packages" folder in its installation?
 
I don't now :)
 
4:55 PM
What OS are you on, @Sosi?
 
Windows 8
 
Okay, under Program Files, your installation should be there. Look for the "Legacy Packages" folder somewhere in your Mathematica installation.
 
5:11 PM
I found a folder called "Legacy" in my Mma directory. Is that it? Inside there are 3 "Reference.nb" notebooks.
 
It should be under the Packages folder or something with that name.
 
what are you specifically looking for?
 
If memory serves, Mathematica still keeps some of its old packages around under a "Legacy Packages" folder. In this case, "LinearRegression.m" was the package that did the work of the current LinearModelFit[].
 
5:29 PM
I found that one!
 
Okay, cool. Hopefully, the stuff in there related to p-values has not yet been replaced by a less-than-revealing kernel-level implementation.
It's going to be long reading, so brace yourself. ;)
 
thanks! :)
 
If you see anything in there that starts with "Student", you'd probably want to look into it. :)
 
5:47 PM
@Guesswhoitis. Did you get my email?
 
Hmm, haven't opened GMail yet. Let me check…
Okay, just read it.
 
 
3 hours later…
9:12 PM
@Guesswhoitis. or any moderator. Apparently I goofed, and I included stuff in my original answer here that shouldn't have been there. Can it be expunged?
@RajAcharya hola
 
@rcollyer, the stuff in the second edit?
 
@Guesswhoitis. the original version of deleted answer. I deleted the answer to limit who saw it, but it really needs to go.
I got the additional info just a moment ago. :P
 
Okay, let me try to contact somebody with expunging abilities…
 
9:26 PM
Here' hoping they respond promptly. Considering it's a Friday where y'all are, tho…
 
yep.
and for the sake of my sanity, the original version of the new answer, too. there are copyright issues, I was not aware of, and the newly removed ones may get pesky, too.
I'll be back later.
 
Next time, check that yer URL's are suitable for public display, mmkay? ;)
 

« first day (1290 days earlier)      last day (3200 days later) »