This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CASE | |
| WHEN to_int("Crime" / 10000) = 1 THEN 'homicide' | |
| WHEN to_int("Crime" / 10000) = 2 THEN 'rape' | |
| WHEN to_int("Crime" / 10000) = 3 THEN 'robbery' | |
| WHEN to_int("Crime" / 10000) = 4 THEN 'assault' | |
| WHEN to_int("Crime" / 10000) = 5 THEN 'burglary' | |
| WHEN to_int("Crime" / 10000) = 6 THEN 'larceny' | |
| WHEN to_int("Crime" / 10000) = 7 THEN 'auto' | |
| WHEN to_int("Crime" / 10000) = 8 THEN 'arson' ELSE '' | |
| END |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| load("sbbsdefs.js"); | |
| load("frame.js"); | |
| // COLOR CODES | |
| var lowRed = '\1N\1R\10'; | |
| var lowBlue = '\1N\1B\10'; | |
| var lowWhite = '\1N\1W\10'; | |
| var highCyan = '\1H\1C\10'; | |
| var lowBlack = '\1N\1K\10'; | |
| var highBlack = '\1H\1K\10'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class ConcatField(agate.Aggregation): | |
| """ | |
| Concatenate every value in a column into a string. | |
| :param column_name: | |
| The name of any column. | |
| """ | |
| def __init__(self, column_name, sep='|'): | |
| self._column_name = column_name | |
| self._sep = sep |
OlderNewer