Search in sources :

Example 11 with Config

use of coloring.Config in project ASCIIGenome by dariober.

the class TrackWigglesTest method canPrintBedGraph.

@Test
public void canPrintBedGraph() throws InvalidGenomicCoordsException, IOException, InvalidRecordException, ClassNotFoundException, SQLException, InvalidColourException, InvalidConfigException {
    new Config(null);
    String url = "test_data/test.bedGraph.gz";
    int yMaxLines = 5;
    GenomicCoords gc = new GenomicCoords("chr1:1-22", 80, null, null);
    TrackWiggles tw = new TrackWiggles(url, gc, 4);
    tw.setYLimitMax(Float.NaN);
    tw.setYLimitMin(Float.NaN);
    tw.setyMaxLines(yMaxLines);
    String prof = tw.printToScreen();
    System.out.println(prof);
    tw = new TrackWiggles("test_data/positive.bedGraph.gz", gc, 4);
    tw.setYLimitMax(Float.NaN);
    tw.setYLimitMin(Float.NaN);
    tw.setyMaxLines(5);
    prof = tw.printToScreen();
    System.out.println(prof);
    tw = new TrackWiggles("test_data/negative.bedGraph.gz", gc, 4);
    tw.setYLimitMax(Float.NaN);
    tw.setYLimitMin(Float.NaN);
    tw.setyMaxLines(5);
    // prof= tw.printToScreen();
    System.out.println(prof);
    gc = new GenomicCoords("chr1:1-52", 80, null, null);
    tw = new TrackWiggles("test_data/posNeg.bedGraph.gz", gc, 4);
    tw.setYLimitMax(Float.NaN);
    tw.setYLimitMin(Float.NaN);
    tw.setyMaxLines(14);
    System.out.println(tw.printToScreen());
}
Also used : GenomicCoords(samTextViewer.GenomicCoords) Config(coloring.Config) Test(org.junit.Test)

Aggregations

Config (coloring.Config)11 Test (org.junit.Test)9 GenomicCoords (samTextViewer.GenomicCoords)8 ArrayList (java.util.ArrayList)4 TrackSet (tracks.TrackSet)2 ConfigKey (coloring.ConfigKey)1 Xterm256 (coloring.Xterm256)1 InvalidColourException (exceptions.InvalidColourException)1 InvalidCommandLineException (exceptions.InvalidCommandLineException)1 InvalidConfigException (exceptions.InvalidConfigException)1 InvalidGenomicCoordsException (exceptions.InvalidGenomicCoordsException)1 InvalidRecordException (exceptions.InvalidRecordException)1 BufferedReader (java.io.BufferedReader)1 IOException (java.io.IOException)1 SQLException (java.sql.SQLException)1 PatternSyntaxException (java.util.regex.PatternSyntaxException)1 ConsoleReader (jline.console.ConsoleReader)1 ArgumentParserException (net.sourceforge.argparse4j.inf.ArgumentParserException)1 Namespace (net.sourceforge.argparse4j.inf.Namespace)1 IntervalFeature (tracks.IntervalFeature)1