org.utgenome.format.wig
Class WIGDatabaseReader

java.lang.Object
  extended by org.utgenome.format.wig.WIGDatabaseReader

public class WIGDatabaseReader
extends Object

Wig database (sqlite) reader

Author:
yoshimura, leo

Nested Class Summary
static class WIGDatabaseReader.AvgSelector
           
static class WIGDatabaseReader.MAXSelector
           
static class WIGDatabaseReader.MedianSelector
           
static class WIGDatabaseReader.MINSelector
           
 
Constructor Summary
WIGDatabaseReader(File file, GraphWindow windowFunc)
           
WIGDatabaseReader(String inputFileURL, GraphWindow windowFunc)
           
 
Method Summary
 void close()
           
static CompactWIGData convertResolution(WigGraphData w, ChrLoc location, int windowWidth)
           
 CompactWIGData fillPixelsWithMedian(CompactWIGData cwig, int pixelWidth, int trackId, int start, int end)
           
 ArrayList<String> getBrowser()
           
 ArrayList<String> getChromList()
           
 CompactWIGData getCompactWigData(int trackId, int start, int end, int pixelWidth)
           
static List<CompactWIGData> getCompactWigDataList(File path, int pixelWidth, ChrLoc location, GraphWindow windowFunc)
           
 HashMap<Integer,Float> getData(int trackId)
           
 HashMap<Integer,Float> getData(int trackId, int start, int end)
           
 HashMap<Integer,Float> getData(int windowWidth, int trackId, int start, int end)
           
static List<CompactWIGData> getRoughCompactWigDataList(File path, int pixelWidth, ChrLoc location, GraphWindow windowFunc)
           
 HashMap<String,String> getTrack(int trackId)
           
 ArrayList<Integer> getTrackIdList()
           
 ArrayList<Integer> getTrackIdList(String chrom)
           
 WigGraphData getWigData(int trackId)
           
 WigGraphData getWigData(int trackId, int start, int end)
           
 WigGraphData getWigData(int windowWidth, int trackId, int start, int end)
           
static List<WigGraphData> getWigDataList(File fileName, int windowWidth, ChrLoc location, GraphWindow windowFunc)
           
 ArrayList<WigGraphData> getWigDataList(int windowWidth, String chrom, int start, int end)
           
 ArrayList<WigGraphData> getWigDataList(String chrom, int start, int end)
           
static CompactWIGData prepareCompactWigData(WigGraphData w, ChrLoc location)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WIGDatabaseReader

public WIGDatabaseReader(File file,
                         GraphWindow windowFunc)
                  throws UTGBException
Throws:
UTGBException

WIGDatabaseReader

public WIGDatabaseReader(String inputFileURL,
                         GraphWindow windowFunc)
                  throws UTGBException
Throws:
UTGBException
Method Detail

close

public void close()
           throws SQLException
Throws:
SQLException

getBrowser

public ArrayList<String> getBrowser()
                             throws SQLException
Throws:
SQLException

getTrackIdList

public ArrayList<Integer> getTrackIdList(String chrom)
                                  throws SQLException
Throws:
SQLException

getTrackIdList

public ArrayList<Integer> getTrackIdList()
                                  throws SQLException
Throws:
SQLException

getChromList

public ArrayList<String> getChromList()
                               throws SQLException
Throws:
SQLException

getTrack

public HashMap<String,String> getTrack(int trackId)
                                throws SQLException
Throws:
SQLException

getData

public HashMap<Integer,Float> getData(int trackId,
                                      int start,
                                      int end)
                               throws SQLException,
                                      IOException,
                                      DataFormatException,
                                      NumberFormatException,
                                      ClassNotFoundException,
                                      UTGBException
Throws:
SQLException
IOException
DataFormatException
NumberFormatException
ClassNotFoundException
UTGBException

fillPixelsWithMedian

public CompactWIGData fillPixelsWithMedian(CompactWIGData cwig,
                                           int pixelWidth,
                                           int trackId,
                                           int start,
                                           int end)
                                    throws SQLException,
                                           UTGBException
Throws:
SQLException
UTGBException

getData

public HashMap<Integer,Float> getData(int windowWidth,
                                      int trackId,
                                      int start,
                                      int end)
                               throws SQLException,
                                      IOException,
                                      DataFormatException,
                                      NumberFormatException,
                                      ClassNotFoundException,
                                      UTGBException
Throws:
SQLException
IOException
DataFormatException
NumberFormatException
ClassNotFoundException
UTGBException

getData

public HashMap<Integer,Float> getData(int trackId)
                               throws NumberFormatException,
                                      SQLException,
                                      IOException,
                                      DataFormatException,
                                      ClassNotFoundException,
                                      UTGBException
Throws:
NumberFormatException
SQLException
IOException
DataFormatException
ClassNotFoundException
UTGBException

getWigData

public WigGraphData getWigData(int windowWidth,
                               int trackId,
                               int start,
                               int end)
                        throws SQLException,
                               NumberFormatException,
                               IOException,
                               DataFormatException,
                               ClassNotFoundException,
                               UTGBException
Throws:
SQLException
NumberFormatException
IOException
DataFormatException
ClassNotFoundException
UTGBException

getWigData

public WigGraphData getWigData(int trackId,
                               int start,
                               int end)
                        throws SQLException,
                               NumberFormatException,
                               IOException,
                               DataFormatException,
                               ClassNotFoundException,
                               UTGBException
Throws:
SQLException
NumberFormatException
IOException
DataFormatException
ClassNotFoundException
UTGBException

getCompactWigData

public CompactWIGData getCompactWigData(int trackId,
                                        int start,
                                        int end,
                                        int pixelWidth)
                                 throws SQLException,
                                        UTGBException
Throws:
SQLException
UTGBException

getWigData

public WigGraphData getWigData(int trackId)
                        throws SQLException,
                               NumberFormatException,
                               IOException,
                               DataFormatException,
                               ClassNotFoundException,
                               UTGBException
Throws:
SQLException
NumberFormatException
IOException
DataFormatException
ClassNotFoundException
UTGBException

getWigDataList

public ArrayList<WigGraphData> getWigDataList(int windowWidth,
                                              String chrom,
                                              int start,
                                              int end)
                                       throws SQLException,
                                              NumberFormatException,
                                              IOException,
                                              DataFormatException,
                                              ClassNotFoundException,
                                              UTGBException
Throws:
SQLException
NumberFormatException
IOException
DataFormatException
ClassNotFoundException
UTGBException

getWigDataList

public ArrayList<WigGraphData> getWigDataList(String chrom,
                                              int start,
                                              int end)
                                       throws SQLException,
                                              NumberFormatException,
                                              IOException,
                                              DataFormatException,
                                              ClassNotFoundException,
                                              UTGBException
Throws:
SQLException
NumberFormatException
IOException
DataFormatException
ClassNotFoundException
UTGBException

getWigDataList

public static List<WigGraphData> getWigDataList(File fileName,
                                                int windowWidth,
                                                ChrLoc location,
                                                GraphWindow windowFunc)
                                         throws UTGBException,
                                                SQLException
Throws:
UTGBException
SQLException

getRoughCompactWigDataList

public static List<CompactWIGData> getRoughCompactWigDataList(File path,
                                                              int pixelWidth,
                                                              ChrLoc location,
                                                              GraphWindow windowFunc)
                                                       throws UTGBException,
                                                              SQLException
Throws:
UTGBException
SQLException

getCompactWigDataList

public static List<CompactWIGData> getCompactWigDataList(File path,
                                                         int pixelWidth,
                                                         ChrLoc location,
                                                         GraphWindow windowFunc)
                                                  throws UTGBException,
                                                         SQLException
Throws:
UTGBException
SQLException

prepareCompactWigData

public static CompactWIGData prepareCompactWigData(WigGraphData w,
                                                   ChrLoc location)

convertResolution

public static CompactWIGData convertResolution(WigGraphData w,
                                               ChrLoc location,
                                               int windowWidth)


Copyright © 2007-2012 utgenome.org. All Rights Reserved.