<commit_before>var _ = require('underscore');
var Backbone = require('backbone');
var cdb = require('cartodb.js');

var QUERY = [
  'select tag.name, to_json(ARRAY(',
  '  select row_to_json(',
  '    (select row(_) from (select o.name, o.id, array_agg(',
  '      (select row(__) from (select tt.name, tt.id) as __)',
  '    ) as columns) as _)',
  '  )',
  '  from obs_tag o ',
  '  join obs_column_tag t on t.tag_id = o.id and t.column_id in (select ttt.column_id from obs_column_tag ttt where ttt.tag_id = tag.id)',
  '  join obs_column tt on tt.id = t.column_id',
  "  where o.type = 'subsection'",
  '  group by o.name, o.id',<commit_msg>Only show columns with weight > 0 in analysis<commit_after>var _ = require('underscore');
var Backbone = require('backbone');
var cdb = require('cartodb.js');

var QUERY = [
  'select tag.name, to_json(ARRAY(',
  '  select row_to_json(',
  '    (select row(_) from (select o.name, o.id, array_agg(',
  '      (select row(__) from (select tt.name, tt.id) as __)',
  '    ) as columns) as _)',
  '  )',
  '  from obs_tag o ',
  '  join obs_column_tag t on t.tag_id = o.id and t.column_id in (select ttt.column_id from obs_column_tag ttt where ttt.tag_id = tag.id)',
  '  join obs_column tt on tt.id = t.column_id',
  "  where o.type = 'subsection'",
  '    and tt.weight > 0 '
  '  group by o.name, o.id',
{'fraction_non_alphanumeric': 0.15812917594654788, 'fraction_numerical': 0.0014847809948032665, 'mean_word_length': 3.2793650793650793, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7065104', 'n_tokens_mistral': 526, 'n_tokens_neox': 519, 'n_words': 139}