1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
{-|
Module : Gargantext.Viz.Phylo.PhyloExport
Description : Exportation module of a Phylo
Copyright : (c) CNRS, 2017-Present
License : AGPL + CECILL v3
Maintainer : team@gargantext.org
Stability : experimental
Portability : POSIX
-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE MultiParamTypeClasses #-}
module Gargantext.Viz.Phylo.PhyloExport where
import Gargantext.Prelude
import Gargantext.Viz.AdaptativePhylo
import Gargantext.Viz.Phylo.PhyloTools
import Data.GraphViz.Types.Generalised (DotGraph)
--------------------
-- | Dot export | --
--------------------
toDot :: [PhyloGroup] -> DotGraph DotId
toDot branches = undefined
----------------------
-- | post process | --
----------------------
processFilters :: [PhyloGroup] -> [PhyloGroup]
processFilters branches = branches
processSort :: [PhyloGroup] -> [PhyloGroup]
processSort branches = branches
processMetrics :: [PhyloGroup] -> [PhyloGroup]
processMetrics branches = branches
processDynamics :: [PhyloGroup] -> [PhyloGroup]
processDynamics branches = branches
processLabels :: [PhyloGroup] -> [PhyloGroup]
processLabels branches = branches
phyloPostProcess :: [PhyloGroup] -> [PhyloGroup]
phyloPostProcess branches = branches
---------------------
-- | phyloExport | --
---------------------
toPhyloExport :: Phylo -> DotGraph DotId
toPhyloExport phylo = toDot
$ phyloPostProcess groups
where
groups :: [PhyloGroup]
groups = getGroupsFromLevel (phyloLevel $ getConfig phylo) phylo