Hello,
I have two questions about regex.
- Below I've shown some code. I'm creating formula columns that parse information from another column. The formulas grab the correct information, but ALWAYS stop at row 3024. The datasets I work with can be tens or rows, or much larger.
dt << New column( "Column 1", formula( regex( :Other column, "pattern" ) ) );
dt << New column( "Column 2", formula( regex( :Other column, "pattern", "\1" ) ) );
dt << New column( "Column 3", formula( num( regex( :Other column, "pattern" ) ) ) );
dt << Rerun Formulas; // Doesn't help!
- In the debugger, timing my script, the timer states that the script is complete in ~1 second, and that these three lines of code take up the bulk of the time. There are other small things going on as well. However, most often, JMP locks up when running it and I have to either stop the script from running in the debugger, or I have to end the task in task manager.
I've used regex in a for() and for each() and had similar issues. However, regex seems like for() and for each() more, as the formula routinely finished, but the time it takes to compete the script run locks up JMP and takes a very long time, if it finishes at all.
This is very basic regex scripting. I've done much more complex things in for loops for other projects, with much larger datasets. The dataset itself was imported as a CSV, but this is the only difference I can spot between it and other datasets. Any ideas as to what's happening?
Learning every day!