Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
clustering-louvain
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
clustering-louvain
Commits
66def5aa
Commit
66def5aa
authored
Jul 28, 2016
by
delanoe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Just exporting one function.
parent
e59c3846
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
GexfParser.hs
src/Data/GexfParser.hs
+4
-3
No files found.
src/Data/GexfParser.hs
View file @
66def5aa
{-# LANGUAGE Arrows, NoMonomorphismRestriction #-}
module
Data.GexfParser
where
module
Data.GexfParser
(
importGraphFromGexf
)
where
import
Text.XML.HXT.Core
import
qualified
Data.Graph
as
DataGraph
...
...
@@ -65,8 +66,8 @@ importGraph file = do
--importGraph' :: FilePath -> IO [(Int, [Int])]
importGraph'
file
=
runX
(
readDocument
[
withValidate
no
]
file
>>>
parseGraph
)
importGraph
''
::
FilePath
->
IO
[
FGL
.
LEdge
Double
]
importGraph
''
file
=
Prelude
.
map
(
\
(
a
,
b
)
->
(
read
a
,
read
b
,
1
))
<$>
edges
<$>
head
<$>
importGraph'
file
importGraph
FromGexf
::
FilePath
->
IO
[
FGL
.
LEdge
Double
]
importGraph
FromGexf
file
=
Prelude
.
map
(
\
(
a
,
b
)
->
(
read
a
,
read
b
,
1
))
<$>
edges
<$>
head
<$>
importGraph'
file
--main :: IO()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment