Haskell Data Analysis Cookbook by 2014

Haskell Data Analysis Cookbook by 2014

Author:2014
Language: eng
Format: mobi
Publisher: Packt Publishing


Getting ready

Install the DAWG package using cabal:

$ cabal install dawg

How to do it...

We name a new file Main.hs and insert the following code:

Import the following packages:import qualified Data.DAWG.Static as D import Network.HTTP ( simpleHTTP, getRequest, getResponseBody) import Data.Char (toLower, isAlphaNum, isSpace) import Data.Maybe (isJust)

In main, download a large corpus of text to store:main = do let url = "http://norvig.com/big.txt" body <- simpleHTTP (getRequest url) >>= getResponseBody



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.