Reputation
33,134
Next tag badge:
175/100 score
19/20 answers
Badges
2 72 146
Newest
 Nice Answer
Impact
~169k people reached

17h
comment Why are my associations not consistantly followed?
1*^-10 is a shorthand notation for 1 * 10^-10. In this case, 10^-10 would be adequate. Will this change fix the problem? If so, then I think we should probably close this question (simple mistake, too localized).
1d
comment Why are my associations not consistantly followed?
I notice that if all occurrences of 1^-10 (i.e. 1) are changed to 1*^-10 (i.e. 0.0000000001), then Glass always appears before Gauge and Door in the output.
Apr
16
comment Is there a linter to help write good Mathematica code?
I don't know of one, but it would be cool to have warnings for private symbols that start with an uppercase letter, implicit multiplications at line boundaries, and unlocalized iterator variables in Table constructs within functions (just to name the first few ideas that popped into my head). The pitfalls post would be an excellent source of inspiration for checks to implement. I wonder if a bit of spelunking would turn up a way to extend the front-end's existing bare-bone checks?
Apr
12
comment How can I change some elements in dataset by related column and row
So you want to change all row_5 entries, even when the value is not zero?
Apr
10
comment How can I add a column into a existing Dataset?
@HyperGroups When a key name is not a valid symbol we can write, for example, #["col_name"].
Apr
9
comment No function to enter value in a different base?
^^ also treats the digits as a string even though syntactically it allows us to omit the quotes. Consider: 16^^face == FromDigits["face", 16].
Apr
5
comment How to construct a dataset with lists as columns
@MikeHoneychurch Yes, I tend to avoid Dataset myself. Its main purpose is to visualize data and I find its visualizations to be problematic maybe 50% of the time. It seems to be overly sensitive to the inferred data types, especially when associations are involved. And a moving target, as you say. Query, on the other hand, I have grown to like. It is more stable than Dataset and I find the "generalized index notation" to be very expressive.
Apr
3
comment Implementing Local HTTP Server
A small-scale web server implemented using ProcessLink and Go can be found here.
Mar
17
comment Error retrieving information of a package function
I think this is a duplicate of Dataset seems to break Information.
Mar
13
comment How to interpret and extract the information from the JSON (JavaScript Object Notation)?
@NelsonMok Getting data into a dataset object is as simple as writing Dataset[data] -- although Dataset does not currently do a very good job of visualizing arbitrary JSON data. You might be better off to leave it in association form and access it using Query or the techniques described in (3111) or (103965).
Feb
26
comment Find subexpression to minimize leafcount after replacment with temporary variable
@ÅsmundHj Sorry, but I have no knowledge concerning the upper limits of this machinery.
Feb
24
comment How do I define a collections of commands for later use?
Take a look at the section in the documentation entitled Defining Functions.
Feb
23
comment How to convert a sparse matrix to a list of sparse arrays?
@rhermans I added the section Why Does This Work?
Feb
19
comment Apply multiple functions to same list
@Mr.Wizard Your points are absolutely valid, but as usual you and I have different pain thresholds when labelling something as "much slower" :D Using Normal @ Query[...] will eliminate both the semantic differences and the performance differences since the query will then be compiled down to a wafer-thin wrapper over Through (the canonical answer). But I find myself using Query as-is with increasing frequency these days because its one-stop-shopping syntactic convenience usually overshadows the other considerations (for me, YMMV).
Feb
17
comment Reshaping associations, generalization of GroupBy
Yes, it does. Thanks.
Feb
17
comment Reshaping associations, generalization of GroupBy
I think that the associations in the source data introduce complexities that differentiate this question from the former one. For example, care must be taken to deal with groups with single entries (e.g. try changing the type of the first entry from "a" to "z"). Also, I got the impression that it was important to be able to specify the grouping keys explicitly rather than implicitly assuming that the data is to be grouped by the two left-most keys appearing in a fixed order in every entry. Neither of these issues arise in the other question.
Jan
24
comment Why is a longer pattern matched rather than a short pattern?
+1 This analysis is correct for ReplaceList which only visits the outermost level. ReplaceAll descends into subparts, so for it there are three valid possibilities (p[a.b, c.d], p[a, b.c.d] . b, a . p[b, c.d.a]). Only one (the first, being the "outermost leftmost") is returned because these possibilities overlap and ReplaceAll only visits any given part once.
Jan
15
comment Average dataset with many repetitions?
@MikeHoneychurch ilian of WRI has acknowledged the singleton list issue on another comment thread.
Jan
15
comment Average dataset with many repetitions?
@MikeHoneychurch Mean alone triggers this bug. WRI claims it was broken in 10.3.0 and fixed in 10.3.1, but on Windows I still see the wrong result in 10.3.1 when Mean is applied to a list containing a single association (no crash though). Merge@Mean is the workaround.
Jan
15
comment Aggregation queries on lists of associations in 10.3
@ilian I see you marked this issue as fixed in 10.3.1, but I still see the wrong result for Mean[{<|"a" -> 1, "b" -> 2|>}] in that release but not in 10.2 or earlier (using Windows 7 x64).