let string_to_wig ?filename () =
let wig_parser =
Wig.Transform.string_to_t ?filename () in
embed_parser ?filename
(*
let track_parser = string_to_string_content ?filename () in
Biocaml_transform.filter_compose
track_parser
~destruct:(function
| Ok (`content s) -> `Yes (s ^ "\n")
| Ok (`track _) | Ok (`browser _) | Ok (`comment _)
| Error _ as n -> `No n) *)
wig_parser
~reconstruct:(function
| `Filtered (Ok f) -> Ok (f :> wig_t)
| `Filtered (Error f) -> Error (f :> wig_parser_error)
| `Done (Ok o) -> Ok (o :> wig_t)
| `Done (Error e) -> Error (e :> wig_parser_error))