]> Git — Sourcephile - gargantext.git/blob - src/Gargantext/Ngrams/TFICF.hs
[FIS][FIX] Frequent Item Set and fix ngrams extraction test.
[gargantext.git] / src / Gargantext / Ngrams / TFICF.hs
1 {-|
2 Module : Gargantext.Ngrams.TFICF
3 Description : TFICF Ngrams tools
4 Copyright : (c) CNRS, 2017
5 License : AGPL + CECILL v3
6 Maintainer : team@gargantext.org
7 Stability : experimental
8 Portability : POSIX
9
10 Definition of TFICF
11
12 -}
13
14 {-# LANGUAGE DeriveGeneric #-}
15
16 module Gargantext.Ngrams.TFICF where
17
18 import GHC.Generics (Generic)
19
20 import Data.Maybe (Maybe)
21 import Data.Text (Text)
22 import Text.Show (Show())
23
24 -- import Gargantext.Types
25 import Gargantext.Prelude
26
27
28 data Context = Corpus | Document
29 deriving (Show, Generic)
30
31 data TFICF = TFICF { _tficfTerms :: Text
32 , _tficfContext1 :: Context
33 , _tficfContext2 :: Context
34 , _tficfScore :: Maybe Double
35 } deriving (Show, Generic)
36
37
38 --tfidf :: Text -> TFICF
39 --tfidf txt = TFICF txt Document Corpus score
40 -- where
41 -- score = Nothing
42