![]() You can use toString() to convert numbers to strings with rounding, using an optional string format. Takes any value type (string, number, date, boolean, error, null) and gives a string version of that value. Returns the length of string s as a number. ![]() For example, (1 < 3).xor(1 < 7) returns false because more than one of the conditions is true. Evaluates multiple statements, then returns true if only one of them is true. ![]() Uses the logical operator XOR (exclusive-or) on two or more booleans to output a boolean. For example, not(1 > 7) returns true because 1 > 7 itself is false. Uses the logical operator NOT on a boolean to output a boolean. For example, (1 7) returns true because at least one of the conditions (the first one) is true. Evaluates multiple statements into booleans, then returns true if all of the statements are true. Uses the logical operator AND on two or more booleans to output a boolean. If you wish to use any regex notation, wrap the pattern in forward slashes. In places where OpenRefine will accept a string (s) or a regex pattern (p), you can supply a string by putting it in quotes. Optional arguments will say “(optional)”. We also use shorthands for substring (“sub”) and separator string (“sep”). If a function can take more than one kind of data as input or can output more than one kind of data, that is indicated with more than one letter (as with “s or a”) or with o for object, meaning it can take any type of data (string, boolean, date, number, etc.). Shorthands are used to indicate the kind of data type used in each function: s for string, b for boolean, n for number, d for date, a for array, p for a regex pattern, and o for object (meaning any data type), as well as “null” and “error” data types. Reading this reference įor the reference below, the function is given in full-length notation and the in-text examples are written in dot notation. Besides the reference guide below, OpenRefine's GitHub wiki has a page with many examples and recipes of frequently-used GREL functions.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |