<commit_before>import React from 'react';
import { compose, branch, renderNothing } from 'recompose';
import SurvivalPlotWrapper from '@ncigdc/components/SurvivalPlotWrapper';
import Table, { Tr, Td, Th } from '@ncigdc/uikit/Table';
import { Row } from '@ncigdc/uikit/Flex';
import Tooltip from '@ncigdc/uikit/Tooltip/Tooltip';
import { tableToolTipHint } from '@ncigdc/theme/mixins';
import { stringifyJSONParam } from '@ncigdc/utils/uri';
import { CreateExploreCaseSetButton } from '@ncigdc/modern_components/withSetAction';
import withRouter from '@ncigdc/utils/withRouter';
import Alias from '@ncigdc/components/Alias';

const survivalFilters = [
  {
    op: 'or',
    content: [
      { op: 'not', content: { field: 'diagnoses.days_to_death' } },
      { op: 'not', content: { field: 'diagnoses.days_to_last_follow_up' } },
    ],
  },
  { op: 'not', content: { field: 'diagnoses.vital_status' } },
];

export default compose(
  withRouter,
  branch(
    ({ survivalData }) =>
      !survivalData ||
      !survivalData.rawData ||
      !survivalData.rawData.results.some(Boolean),
    renderNothing,
  ),
)(
  ({
    survivalData,<commit_msg>🐛 [PRTL-1758] update survival filter<commit_after>import React from 'react';
import { compose, branch, renderNothing } from 'recompose';
import SurvivalPlotWrapper from '@ncigdc/components/SurvivalPlotWrapper';
import Table, { Tr, Td, Th } from '@ncigdc/uikit/Table';
import { Row } from '@ncigdc/uikit/Flex';
import Tooltip from '@ncigdc/uikit/Tooltip/Tooltip';
import { tableToolTipHint } from '@ncigdc/theme/mixins';
import { stringifyJSONParam } from '@ncigdc/utils/uri';
import { CreateExploreCaseSetButton } from '@ncigdc/modern_components/withSetAction';
import withRouter from '@ncigdc/utils/withRouter';
import Alias from '@ncigdc/components/Alias';

const survivalFilters = [
  {
    op: 'or',
    content: [
      {
        op: 'and',
        content: [
          { op: '>', content: { field: 'diagnoses.days_to_death', value: 0 } },
        ],
      },
      {
        op: 'and',
        content: [
          {
            op: '>',
            content: { field: 'diagnoses.days_to_last_follow_up', value: 0 },
          },
        ],
      },
    ],
  },
  { op: 'not', content: { field: 'diagnoses.vital_status' } },
];

export default compose(
  withRouter,
  branch(
    ({ survivalData }) =>
      !survivalData ||
      !survivalData.rawData ||
      !survivalData.rawData.results.some(Boolean),
    renderNothing,
  ),
)(
  ({
    survivalData,
{'fraction_non_alphanumeric': 0.14780876494023903, 'fraction_numerical': 0.002390438247011952, 'mean_word_length': 3.4363957597173145, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '2893040', 'n_tokens_mistral': 860, 'n_tokens_neox': 830, 'n_words': 171}