rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
byte[] thisMarker; | byte kid1, kid2; | public Vector linkageToChrom(File infile, int type) throws IllegalArgumentException, HaploViewException, PedFileException, IOException{ pedFile = new PedFile(); if (type == PED_FILE){ pedFile.parseLinkage(infile); }else{ pedFile.parseHapMap(infile); ... |
thisMarker = zeroArray; }else{ thisMarker = currentInd.getMarker(i); } byte kid1 = thisMarker[0]; byte kid2 = thisMarker[1]; | kid1 = 0; kid2 = 0; }else{ kid1 = currentInd.getMarkerA(i); kid2 = currentInd.getMarkerB(i); } byte mom1,mom2; | public Vector linkageToChrom(File infile, int type) throws IllegalArgumentException, HaploViewException, PedFileException, IOException{ pedFile = new PedFile(); if (type == PED_FILE){ pedFile.parseLinkage(infile); }else{ pedFile.parseHapMap(infile); ... |
thisMarker = zeroArray; }else{ thisMarker = (currentFamily.getMember(currentInd.getMomID())).getMarker(i); } byte mom1 = thisMarker[0]; byte mom2 = thisMarker[1]; | mom1 = 0; mom2 = 0; }else{ mom1 = (currentFamily.getMember(currentInd.getMomID())).getMarkerA(i); mom2 = (currentFamily.getMember(currentInd.getMomID())).getMarkerB(i); } byte dad1,dad2; | public Vector linkageToChrom(File infile, int type) throws IllegalArgumentException, HaploViewException, PedFileException, IOException{ pedFile = new PedFile(); if (type == PED_FILE){ pedFile.parseLinkage(infile); }else{ pedFile.parseHapMap(infile); ... |
thisMarker = zeroArray; }else{ thisMarker = (currentFamily.getMember(currentInd.getDadID())).getMarker(i); } byte dad1 = thisMarker[0]; byte dad2 = thisMarker[1]; | dad1 = 0; dad2 = 0; }else{ dad1 = (currentFamily.getMember(currentInd.getDadID())).getMarkerA(i); dad2 = (currentFamily.getMember(currentInd.getDadID())).getMarkerB(i); } | public Vector linkageToChrom(File infile, int type) throws IllegalArgumentException, HaploViewException, PedFileException, IOException{ pedFile = new PedFile(); if (type == PED_FILE){ pedFile.parseLinkage(infile); }else{ pedFile.parseHapMap(infile); ... |
byte[] thisMarker; | byte thisMarkerA, thisMarkerB; | public Vector linkageToChrom(File infile, int type) throws IllegalArgumentException, HaploViewException, PedFileException, IOException{ pedFile = new PedFile(); if (type == PED_FILE){ pedFile.parseLinkage(infile); }else{ pedFile.parseHapMap(infile); ... |
thisMarker = zeroArray; }else{ thisMarker = currentInd.getMarker(i); } if (thisMarker[0] == thisMarker[1] || thisMarker[0] == 0 || thisMarker[1] == 0){ chrom1[i] = thisMarker[0]; chrom2[i] = thisMarker[1]; }else{ chrom1[i] = (byte)(4+thisMarker[0]); chrom2[i] = (byte)(4+thisMarker[1]); | thisMarkerA = 0; thisMarkerB = 0; }else{ thisMarkerA = currentInd.getMarkerA(i); thisMarkerB = currentInd.getMarkerB(i); } if (thisMarkerA == thisMarkerB || thisMarkerA == 0 || thisMarkerB == 0){ chrom1[i] = thisMarkerA; chrom2[i] = thisMarkerB; }else{ chrom1[i] = (byte)(4+thisMarkerA); chrom2[i] = (byte)(4+thisMarkerB... | public Vector linkageToChrom(File infile, int type) throws IllegalArgumentException, HaploViewException, PedFileException, IOException{ pedFile = new PedFile(); if (type == PED_FILE){ pedFile.parseLinkage(infile); }else{ pedFile.parseHapMap(infile); ... |
Vector unsortedMarkers = ind.getMarkers(); | byte[] sortedMarkersa = new byte[ind.getNumMarkers()]; byte[] sortedMarkersb = new byte[ind.getNumMarkers()]; | void prepareMarkerInput(File infile, String[][] hapmapGoodies) throws IOException, HaploViewException{ //this method is called to gather data about the markers used. //It is assumed that the input file is two columns, the first being //the name and the second the absolute position. the maxdist ... |
boolean[] sortedZeroed = new boolean[unsortedMarkers.size()]; Vector sortedMarkers = new Vector(); for (int j = 0; j < unsortedMarkers.size(); j++){ sortedMarkers.add(unsortedMarkers.get(realPos[j])); | boolean[] sortedZeroed = new boolean[unsortedZeroed.length]; for (int j = 0; j < ind.getNumMarkers(); j++){ sortedMarkersa[j] = ind.getMarkerA(realPos[j]); sortedMarkersb[j] = ind.getMarkerB(realPos[j]); | void prepareMarkerInput(File infile, String[][] hapmapGoodies) throws IOException, HaploViewException{ //this method is called to gather data about the markers used. //It is assumed that the input file is two columns, the first being //the name and the second the absolute position. the maxdist ... |
ind.setMarkers(new Vector(sortedMarkers)); | ind.setMarkers(sortedMarkersa, sortedMarkersb); | void prepareMarkerInput(File infile, String[][] hapmapGoodies) throws IOException, HaploViewException{ //this method is called to gather data about the markers used. //It is assumed that the input file is two columns, the first being //the name and the second the absolute position. the maxdist ... |
Map params = config.getParamValues(); final String jndiFactory = (String)params.get(JSR160ApplicationConfig.JNDI_FACTORY); final String jndiURL = (String)params.get(JSR160ApplicationConfig.JNDI_URL); if(jndiFactory != null) env.put(JSR160ApplicationConfig.JNDI_FACTORY, jndiFactory); if(jndiURL != null) env.put(JSR160A... | public ServerConnection getServerConnection(ApplicationConfig config) throws ConnectionFailedException { try { /* Create an RMI connector client */ HashMap env = new HashMap(); String[] credentials = new String[] {config.getUsername(), ... | |
org.apache.log4j.Logger folderLog = org.apache.log4j.Logger.getLogger( PhotoFolder.class.getName() ); folderLog.setLevel( org.apache.log4j.Level.DEBUG ); | public static void main( String[] args ) { org.apache.log4j.BasicConfigurator.configure(); log.setLevel( org.apache.log4j.Level.DEBUG ); junit.textui.TestRunner.run( suite() ); } | |
PhotoFolder subfolder = PhotoFolder.create( "New subfolder", folder ); assertTrue( "Not notified of subfolder structure change", l1.structureModified ); assertEquals( "subfolder info not correct", folder, l1.structChangeFolder ); l1.structureModified = false; l1.changedFolder = null; subfolder.setDescription( "Changed... | public void testListener() { PhotoFolder folder = PhotoFolder.create( "testListener", null ); TestListener l1 = new TestListener(); TestListener l2 = new TestListener(); folder.addPhotoCollectionChangeListener( l1 ); folder.addPhotoCollectionChangeListener( l2 ); folder.setName( "testLiistener" ); assertTrue( "l1 n... | |
plinkFilters = null; | void readWGA(String[] inputOptions) { String wgaFile = inputOptions[0]; String mapFile = inputOptions[1]; String secondaryFile = inputOptions[2]; String embeddedMap = inputOptions[3]; boolean embed = false; this.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR)); ... | |
final JellyContext newContext = new JellyContext(context); | final JellyContext newContext = context.newJellyContext(); | public void doTag(final XMLOutput output) throws Exception { if ( xmlOutput == null ) { // lets default to system.out xmlOutput = XMLOutput.createXMLOutput( System.out ); } // lets create a child context final JellyContext newContext = new JellyContext(context); ... |
xmlOutput.close(); | if (closeOutput) { xmlOutput.close(); } else { xmlOutput.flush(); } | public void doTag(final XMLOutput output) throws Exception { if ( xmlOutput == null ) { // lets default to system.out xmlOutput = XMLOutput.createXMLOutput( System.out ); } // lets create a child context final JellyContext newContext = new JellyContext(context); ... |
xmlOutput.close(); | if (closeOutput) { xmlOutput.close(); } else { xmlOutput.flush(); } | public void run() { try { getBody().run(newContext, xmlOutput); xmlOutput.close(); } catch (Exception e) { e.printStackTrace(); } } |
this.closeOutput = true; | public void setFile(String name) throws IOException { setXmlOutput( XMLOutput.createXMLOutput(new FileOutputStream(name)) ); } | |
this.closeOutput = false; | public void setXmlOutput(XMLOutput xmlOutput) { this.xmlOutput = xmlOutput; } | |
DataSource src = connDesc.getDataSource(); | public void upgradeDatabase() { fireStatusChangeEvent( new SchemaUpdateEvent( PHASE_ALTERING_SCHEMA, 0 ) ); int oldVersion = db.getSchemaVersion(); // Find needed information fr DdlUtils ConnectionRepository cr = MetadataManager.getInstance().connectionRepository(); ... | |
if (Options.getAssocTest() == ASSOC_TRIO){ results[k][z].setTransCount(theEM.getTransCount(z)); results[k][z].setUntransCount(theEM.getUntransCount(z)); }else if (Options.getAssocTest() == ASSOC_CC){ results[k][z].setCaseFreq(theEM.getCaseFreq(z)); results[k][z].setControlFreq(theEM.getControlFreq(z)); } | Haplotype[][] generateHaplotypes(Vector blocks, int hapthresh, boolean crossover) throws HaploViewException{ //TODO: output indiv hap estimates Haplotype[][] results = new Haplotype[blocks.size()][]; //String raw = new String(); //String currentLine; this.totalBlocks = blocks.size... | |
while (test.evaluateAsBoolean(getContext())) { | try { while (test.evaluateAsBoolean(getContext())) { if (log.isDebugEnabled()) { log.debug("evaluated to true! gonna keep on chuggin!"); } invokeBody(output); } } catch (BreakException e) { | public void doTag(XMLOutput output) throws MissingAttributeException, Exception { if (test != null) { while (test.evaluateAsBoolean(getContext())) { if (log.isDebugEnabled()) { log.debug("evaluated to true! gonna keep on chuggin!"); } ... |
log.debug("evaluated to true! gonna keep on chuggin!"); | log.debug("loop terminated by break: " + e, e); | public void doTag(XMLOutput output) throws MissingAttributeException, Exception { if (test != null) { while (test.evaluateAsBoolean(getContext())) { if (log.isDebugEnabled()) { log.debug("evaluated to true! gonna keep on chuggin!"); } ... |
invokeBody(output); | public void doTag(XMLOutput output) throws MissingAttributeException, Exception { if (test != null) { while (test.evaluateAsBoolean(getContext())) { if (log.isDebugEnabled()) { log.debug("evaluated to true! gonna keep on chuggin!"); } ... | |
this (pp, pp.findTablePane(model.getPkTable()), pp.findTablePane(model.getFkTable())); | this.pp = pp; this.model = model; setPkTable(pp.findTablePane(model.getPkTable())); setFkTable(pp.findTablePane(model.getFkTable())); setup(); | public Relationship(PlayPen pp, SQLRelationship model) throws ArchitectException { this (pp, pp.findTablePane(model.getPkTable()), pp.findTablePane(model.getFkTable())); } |
dPrimeDisplay.setVisible(false); dPrimeDisplay.setVisible(true); | public void stateChanged(ChangeEvent e) { viewMenuItems[tabs.getSelectedIndex()].setSelected(true); if (checkPanel != null && checkPanel.changed){ window.setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR)); JTable table = checkPanel.getTable(); ... | |
}else if (command == "Zoomed"){ if (dPrimeDisplay != null){ dPrimeDisplay.zoom(0); } }else if (command == "Medium"){ if (dPrimeDisplay != null){ dPrimeDisplay.zoom(1); } }else if (command == "Unzoomed"){ if (dPrimeDisplay != null){ dPrimeDisplay.zoom(2); } | public void actionPerformed(ActionEvent e) { String command = e.getActionCommand(); if (command == READ_GENOTYPES){ ReadDataDialog readDialog = new ReadDataDialog("Open new data", this); readDialog.pack(); readDialog.setVisible(true); } else if (command == READ_... | |
affSingletons.add(new Integer(thisChrom.getAffected())); | if(addAff) { affSingletons.add(new Integer(thisChrom.getAffected())); } | public void doEM(int[] theBlock) throws HaploViewException{ //break up large blocks if needed int[] block_size; if (theBlock.length < 9){ block_size = new int[1]; block_size[0] = theBlock.length; } else { //some base-8 arithmetic int ones = the... |
affTrios.add(new Integer(thisChrom.getAffected())); | if(addAff) { affTrios.add(new Integer(thisChrom.getAffected())); } | public void doEM(int[] theBlock) throws HaploViewException{ //break up large blocks if needed int[] block_size; if (theBlock.length < 9){ block_size = new int[1]; block_size[0] = theBlock.length; } else { //some base-8 arithmetic int ones = the... |
affSingletons.add(new Integer(0)); | if(addAff) { affSingletons.add(new Integer(0)); } } if(addAff) { addAff = false; } else { addAff =true; | public void doEM(int[] theBlock) throws HaploViewException{ //break up large blocks if needed int[] block_size; if (theBlock.length < 9){ block_size = new int[1]; block_size[0] = theBlock.length; } else { //some base-8 arithmetic int ones = the... |
retval=false; | retval=true; | boolean kid_consistent(int chap1, int chap2, int num_blocks, int[] block_size, int[][] hlist, int[] num_hlist, int this_trio, int num_loci) { int i, val; boolean retval; int[] temp1 = decode_haplo_str(chap1,num_blocks,block_size,hlist,num_hlist); int[] temp2 = decode_haplo_str(chap2,n... |
if (ambighet[this_trio][i] == 0) { | if (ambighet[this_trio][i] !=0) { | boolean kid_consistent(int chap1, int chap2, int num_blocks, int[] block_size, int[][] hlist, int[] num_hlist, int this_trio, int num_loci) { int i, val; boolean retval; int[] temp1 = decode_haplo_str(chap1,num_blocks,block_size,hlist,num_hlist); int[] temp2 = decode_haplo_str(chap2,n... |
retval=true; | retval=false; | boolean kid_consistent(int chap1, int chap2, int num_blocks, int[] block_size, int[][] hlist, int[] num_hlist, int this_trio, int num_loci) { int i, val; boolean retval; int[] temp1 = decode_haplo_str(chap1,num_blocks,block_size,hlist,num_hlist); int[] temp2 = decode_haplo_str(chap2,n... |
Vector blockResults = new AssociationTestSet(blockHaps, names).getResults(); | Vector blockResults = new AssociationTestSet(blockHaps, names, alleles).getResults(); | public void runFileTests(HaploData theData, Vector inputSNPResults) throws HaploViewException { Vector res = new Vector(); if(tests == null || theData == null) { return; } Vector blocks = new Vector(); Vector names = new Vector(); for(int i=0;i<tests.size();i++) ... |
if (currentTest.getAllele() != null){ boolean foundAllele = false; for (int j = 0; j < har.getAlleleCount(); j++){ if (har.getNumericAlleleName(j).equals(currentTest.getAllele())){ Haplotype[] filtHaps = {har.getHaps()[j]}; res.add(new HaplotypeAssociationResult(filtHaps,0,har.getName())); foundAllele = true; break; } ... | res.add(har); | public void runFileTests(HaploData theData, Vector inputSNPResults) throws HaploViewException { Vector res = new Vector(); if(tests == null || theData == null) { return; } Vector blocks = new Vector(); Vector names = new Vector(); for(int i=0;i<tests.size();i++) ... |
public void doTag(XMLOutput output) throws Exception { | public void doTag(XMLOutput output) { | public void doTag(XMLOutput output) throws Exception { } |
tempVect.add(new Integer(i+1)); | tempVect.add(new Integer(Chromosome.realIndex[i]+1)); | public void refreshTable(){ this.removeAll(); Vector tableData = new Vector(); int numRes = Chromosome.getFilteredSize(); for (int i = 0; i < numRes; i++){ Vector tempVect = new Vector(); TDTResult currentResult = (TDTResult)result.get(Chromosome.realIndex[i]); ... |
set( name, value ); | name = convertVariableName(name); if (name != null) { set( name, value ); } | public void setJellyContext(JellyContext context) throws EvalError { this.context = context; // now pass in all the variables for ( Iterator iter = context.getVariableNames(); iter.hasNext(); ) { String name = (String) iter.next(); Object value = context.getVariabl... |
set( "jellyContext", context ); | set( "context", context ); | public void setJellyContext(JellyContext context) throws EvalError { this.context = context; // now pass in all the variables for ( Iterator iter = context.getVariableNames(); iter.hasNext(); ) { String name = (String) iter.next(); Object value = context.getVariabl... |
if(!AuthConstants.USER_ADMIN.equals(user.getUsername())) userForm.setRole(((Role)user.getRoles().get(0)).getName()); | if(!AuthConstants.USER_ADMIN.equals(user.getUsername())){ String[] roles = new String[user.getRoles().size()]; int ctr = 0; for(Iterator it= user.getRoles().iterator(); it.hasNext();){ roles[ctr++] = ((Role)it.next()).getName(); } userForm.setRole(roles); } | private void prepareUserForm(ActionForm form, User user){ UserForm userForm = (UserForm)form; userForm.setUsername(user.getUsername()); userForm.setPassword(UserForm.FORM_PASSWORD); userForm.setConfirmPassword(UserForm.FORM_PASSWORD); //TODO Need to handle multiple role scenario ... |
"One or more males in the file is heterozygous.\nThese genotypes have been ignored.", | "At least one male in the file is heterozygous.\nThese genotypes have been ignored.", | void readGenotypes(String[] inputOptions, int type){ //input is a 2 element array with //inputOptions[0] = ped file //inputOptions[1] = info file (null if none) //inputOptions[2] = custom association test list file (null if none) //type is either 3 or 4 for ped and hapmap files re... |
throw new RuntimeException( "foo" ); | public AntTagLibrary() { this.project = new Project(); BuildLogger logger = new NoBannerLogger(); logger.setMessageOutputLevel( org.apache.tools.ant.Project.MSG_INFO ); logger.setOutputPrintStream( System.out ); logger.setErrorPrintStream( System.err); project.addBuildListe... | |
return tagFactory.createTag(); | return tagFactory.createTag(localName, getSaxAttributes()); | protected Tag createTag() throws Exception { if ( tagFactory != null) { return tagFactory.createTag(); } return null; } |
logger.debug("Changing nullable "+oldNullable+" -> "+argNullable); | public void setNullable(int argNullable) { int oldNullable = this.nullable; if (this.nullable != argNullable) { this.nullable = argNullable; fireDbObjectChanged("nullable",oldNullable,argNullable); } } | |
SQLObject p = parent; | this.primaryKeySeq = argPrimaryKeySeq; fireDbObjectChanged("primaryKeySeq",oldPrimaryKeySeq,argPrimaryKeySeq); SQLObject p = parent; | public void setPrimaryKeySeq(Integer argPrimaryKeySeq) { // do nothing if there's no change if ( (primaryKeySeq == null && argPrimaryKeySeq == null) || (primaryKeySeq != null && primaryKeySeq.equals(argPrimaryKeySeq)) ) { return; } try { startCompoundEdit("Starting Pri... |
} this.primaryKeySeq = argPrimaryKeySeq; if (p != null) { | public void setPrimaryKeySeq(Integer argPrimaryKeySeq) { // do nothing if there's no change if ( (primaryKeySeq == null && argPrimaryKeySeq == null) || (primaryKeySeq != null && primaryKeySeq.equals(argPrimaryKeySeq)) ) { return; } try { startCompoundEdit("Starting Pri... | |
} fireDbObjectChanged("primaryKeySeq",oldPrimaryKeySeq,argPrimaryKeySeq); | } | public void setPrimaryKeySeq(Integer argPrimaryKeySeq) { // do nothing if there's no change if ( (primaryKeySeq == null && argPrimaryKeySeq == null) || (primaryKeySeq != null && primaryKeySeq.equals(argPrimaryKeySeq)) ) { return; } try { startCompoundEdit("Starting Pri... |
JPanel arsePanel = new JPanel(); arsePanel.setBackground(Color.RED); arsePanel.setPreferredSize(new Dimension(100,100)); arsePanel.setBounds(100,100,200,200); arsePanel.setOpaque(true); | void drawPicture(HaploData theData){ Container contents = getContentPane(); contents.removeAll(); //remember which tab we're in if they've already been set up int currentTabIndex = 0; if (!(tabs == null)){ currentTabIndex = tabs.getSelectedIndex(); } tabs ... | |
HaploView.setDefaultLookAndFeelDecorated(true); | public static void main(String[] args) {//throws IOException{ if(args.length>0){ handleFlags(args); } else { try { UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); } catch (Exception e) { } //setup view object ... | |
g2.scale(zoom, zoom); FontRenderContext frc = g2.getFontRenderContext(); | FontRenderContext frc = null; if (g2 != null) { g2.scale(zoom, zoom); frc = g2.getFontRenderContext(); g2.dispose(); } | public FontRenderContext getFontRenderContext() { Graphics2D g2 = (Graphics2D) getGraphics(); g2.scale(zoom, zoom); FontRenderContext frc = g2.getFontRenderContext(); if (logger.isDebugEnabled()) logger.debug("Returning frc="+frc); return frc; } |
sep = Chromosome.getFilteredMarker(y).getPosition() - Chromosome.getFilteredMarker(x).getPosition(); | sep = Math.abs(Chromosome.getFilteredMarker(y).getPosition() - Chromosome.getFilteredMarker(x).getPosition()); | static Vector doSFS(PairwiseLinkage[][] dPrime){ int numStrong = 0; int numRec = 0; int numInGroup = 0; Vector blocks = new Vector(); Vector strongPairs = new Vector(); //first set up a filter of markers which fail the MAF threshhold boolean[] skipMarker = new boolean[dPrime.lengt... |
int sep = Integer.parseInt((String)((Vector)strongPairs.elementAt(v)).elementAt(2)); | int sep = Math.abs(Integer.parseInt((String)((Vector)strongPairs.elementAt(v)).elementAt(2))); | static Vector doSFS(PairwiseLinkage[][] dPrime){ int numStrong = 0; int numRec = 0; int numInGroup = 0; Vector blocks = new Vector(); Vector strongPairs = new Vector(); //first set up a filter of markers which fail the MAF threshhold boolean[] skipMarker = new boolean[dPrime.lengt... |
Task task = (Task) type.newInstance(); task.setProject(project); task.setTaskName(name); TaskTag tag = new TaskTag( task ); | TaskTag tag = new TaskTag( project, type, name ); | public TagScript createTagScript(String name, Attributes attributes) throws Exception { Project project = getProject(); // custom Ant tags if ( name.equals("fileScanner") ) { Tag tag = new FileScannerTag(new FileScanner(project)); return TagScript.newIn... |
Stylesheet stylesheet = getStylesheet(); if ( stylesheet == null ) { | StylesheetTag tag = (StylesheetTag) findAncestorWithClass( StylesheetTag.class ); if (tag == null) { | public void doTag(XMLOutput output) throws Exception { Stylesheet stylesheet = getStylesheet(); if ( stylesheet == null ) { throw new JellyException( "<applyTemplates> tag must be inside a <stylesheet> tag" ); } Object context = getXPathConte... |
Object context = getXPathContext(); | Stylesheet stylesheet = tag.getStylesheet(); Object source = tag.getXPathSource(); | public void doTag(XMLOutput output) throws Exception { Stylesheet stylesheet = getStylesheet(); if ( stylesheet == null ) { throw new JellyException( "<applyTemplates> tag must be inside a <stylesheet> tag" ); } Object context = getXPathConte... |
stylesheet.applyTemplates( context, select ); | stylesheet.applyTemplates( source, select ); | public void doTag(XMLOutput output) throws Exception { Stylesheet stylesheet = getStylesheet(); if ( stylesheet == null ) { throw new JellyException( "<applyTemplates> tag must be inside a <stylesheet> tag" ); } Object context = getXPathConte... |
stylesheet.applyTemplates( context ); | stylesheet.applyTemplates( source ); | public void doTag(XMLOutput output) throws Exception { Stylesheet stylesheet = getStylesheet(); if ( stylesheet == null ) { throw new JellyException( "<applyTemplates> tag must be inside a <stylesheet> tag" ); } Object context = getXPathConte... |
if(plinkFileName != null){ | if(mapFileName != null){ | private void argHandler(String[] args){ argHandlerMessages = new Vector(); int maxDistance = -1; //this means that user didn't specify any output type if it doesn't get changed below blockOutputType = -1; double hapThresh = -1; double minimumMAF=-1; double spacingThr... |
fc.setSelectedFile(null); | void saveDprimeToText(){ try{ fc.setSelectedFile(null); int returnVal = fc.showSaveDialog(this); if (returnVal == JFileChooser.APPROVE_OPTION) { new TextMethods().saveDprimeToText(theData.dPrimeTable, fc.getSelectedFile(), infoKnown, theData.markerInfo); } }catch (IOException ioexec){ JOptionPa... | |
fc.setSelctedFile(null); | void saveHapsToText(){ try{ fc.setSelectedFile(null); int returnVal = fc.showSaveDialog(this); if (returnVal == JFileChooser.APPROVE_OPTION) { new TextMethods().saveHapsToText(finishedHaplos, fc.getSelectedFile()); } }catch (IOException ioexec){ JOptionPane.showMessageDialog(this, ioexec... | |
super(config); time = System.currentTimeMillis(); | this(config, System.currentTimeMillis()); | public ApplicationEvent(ApplicationConfig config){ super(config); time = System.currentTimeMillis(); } |
public ViewerTag(Class widgetClass) { super(widgetClass); | public ViewerTag(Class tagClass) { super(tagClass); | public ViewerTag(Class widgetClass) { super(widgetClass); } |
public List keysOfColumn(SQLColumn col) throws ArchitectException { LinkedList keys = new LinkedList(); | public List<SQLRelationship> keysOfColumn(SQLColumn col) throws ArchitectException { LinkedList<SQLRelationship> keys = new LinkedList<SQLRelationship>(); | public List keysOfColumn(SQLColumn col) throws ArchitectException { LinkedList keys = new LinkedList(); Iterator it = getExportedKeys().iterator(); while (it.hasNext()) { SQLRelationship r = (SQLRelationship) it.next(); if (r.containsPkColumn(col)) { keys.add(r); } } it = getExportedKeys().iterator(); w... |
System.out.println("Error: One or more males in the file is heterozygous.\nThese genotypes have been ignored."); | System.out.println("Error: At least one male in the file is heterozygous.\nThese genotypes have been ignored."); | private void processFile(String fileName, int fileType, String infoFileName){ try { HaploData textData; File outputFile; File inputFile; AssociationTestSet customAssocSet; if(!quietMode && fileName != null){ System.out.println("Using data ... |
setFrequencyCutoff(((double)freqCutoff)/100); | filterByFrequency(((double)freqCutoff)/100); | public HaplotypeAssociationResult(Haplotype[] locusHaplos, int freqCutoff, String n) { nf.setGroupingUsed(false); for (int i = 0; i < locusHaplos.length; i++){ alleles.add(locusHaplos[i]); } setFrequencyCutoff(((double)freqCutoff)/100); name = n; haps = locusHapl... |
if (i!=j){ | if (h != alleles.get(j)){ | public String getCountString(int i){ nf.setMinimumFractionDigits(1); nf.setMaximumFractionDigits(1); Haplotype h = (Haplotype) filteredAlleles.get(i); StringBuffer countSB = new StringBuffer(); if(Options.getAssocTest() == ASSOC_TRIO) { countSB.append(nf.format(h.getTra... |
public Context getContext() { | public JellyContext getContext() { | public Context getContext() { return context; } |
else if(countOptions == 0) { | else if(countOptions == 0 && nogui) { | private void argHandler(String[] args){ //TODO: -specify values from HaplotypeDisplayController (min hap percentage etc) //TODO: -want to be able to output haps file from pedfile /* boolean nogui = false; String batchMode = ""; String hapsFileName = ""; String pedFileNa... |
logger.debug("displayExceptionDialog: showing exception dialog for:", throwable); | private static void displayExceptionDialog(Component parent, String message, Throwable throwable) { if (parent == null) { logger.error("displayExceptionDialog with null parent for message " + message); } StringWriter traceWriter = new StringWriter(); throwable.printStackTrace(... | |
protected String getBodyText( Context context ) throws Exception { StringWriter writer = new StringWriter(); body.run( context, XMLOutput.createXMLOutput( writer ) ); return writer.toString(); } | protected String getBodyText() throws Exception { StringWriter writer = new StringWriter(); body.run(context, XMLOutput.createXMLOutput(writer)); return writer.toString(); } | protected String getBodyText( Context context ) throws Exception { // XXX: could maybe optimise this later on by having a pool of buffers StringWriter writer = new StringWriter(); body.run( context, XMLOutput.createXMLOutput( writer ) ); return writer.toString(); } |
public void run(Context context, XMLOutput output) throws Exception { getBody().run(context, output); } | public void run(JellyContext context, XMLOutput output) throws Exception { getBody().run(context, output); } | public void run(Context context, XMLOutput output) throws Exception { getBody().run(context, output); } |
getThreadScriptDataMap().clear(); variables.clear(); | clearScriptData(); clearVariables(); | public void clear() { getThreadScriptDataMap().clear(); variables.clear(); } |
threadLocalScriptData = new ThreadLocal(); | threadLocalScriptData.clear(); | public void clearScriptData() { threadLocalScriptData = new ThreadLocal(); } |
Map data = (Map) threadLocalScriptData.get(); | Thread t = Thread.currentThread(); Map data = (Map) threadLocalScriptData.get(t); | public Map getThreadScriptDataMap() { Map rv; Map data = (Map) threadLocalScriptData.get(); if (data == null) { rv = new HashMap(); threadLocalScriptData.set(rv); } else { rv = data; } return rv; } |
threadLocalScriptData.set(rv); | threadLocalScriptData.put(t, rv); | public Map getThreadScriptDataMap() { Map rv; Map data = (Map) threadLocalScriptData.get(); if (data == null) { rv = new HashMap(); threadLocalScriptData.set(rv); } else { rv = data; } return rv; } |
log.debug( "FUZZY_DATE - updateValue ({}) " ); | protected void initModelFields() { modelFields.put( PHOTOGRAPHER, new FieldController( photos ) { protected void setModelValue( Object model ) { PhotoInfo obj = (PhotoInfo) model; obj.setPhotographer( (String) value ); } protected Object getModelValue( Object model ) { if ( model == null ) { ret... | |
log.debug( "FUZZY_DATE - getModeValue ({}) " ); | protected Object getModelValue( Object model ) { PhotoInfo obj = (PhotoInfo) model; Date date = obj.getShootTime(); double accuracy = obj.getTimeAccuracy(); return new FuzzyDate( date, accuracy ); } | |
log.debug( "FUZZY_DATE - setModeValue ({}) " ); | protected void setModelValue( Object model ) { PhotoInfo obj = (PhotoInfo) model; FuzzyDate fd = (FuzzyDate) value; if ( fd != null ) { obj.setShootTime( fd.getDate() ); obj.setTimeAccuracy( fd.getAccuracy() ); } else { obj.setShootTime( null ); obj.setTimeAccuracy( 0 ); } } | |
log.debug( "FUZZY_DATE - updateValue ({}) " ); | protected void updateValue( Object view ) { PhotoInfoView obj = (PhotoInfoView) view; value = obj.getFuzzyDate(); } | |
log.debug( "FUZZY_DATE - updateView ({}) " ); | protected void updateView( Object view ) { PhotoInfoView obj = (PhotoInfoView) view; obj.setFuzzyDate( (FuzzyDate) value ); } | |
if (this.nullable != argNullable) { this.nullable = argNullable; fireDbObjectChanged("nullable",oldNullable,argNullable); } | this.nullable = argNullable; fireDbObjectChanged("nullable",oldNullable,argNullable); | public void setNullable(int argNullable) { int oldNullable = this.nullable; logger.debug("Changing nullable "+oldNullable+" -> "+argNullable); if (this.nullable != argNullable) { this.nullable = argNullable; fireDbObjectChanged("nullable",oldNullable,argNullable); } } |
try { | Integer oldPrimaryKeySeq = primaryKeySeq; if (!isMagicEnabled()) { this.primaryKeySeq = argPrimaryKeySeq; fireDbObjectChanged("primaryKeySeq",oldPrimaryKeySeq,argPrimaryKeySeq); } else try { | public void setPrimaryKeySeq(Integer argPrimaryKeySeq) { // do nothing if there's no change if ( (primaryKeySeq == null && argPrimaryKeySeq == null) || (primaryKeySeq != null && primaryKeySeq.equals(argPrimaryKeySeq)) ) { return; } try { startCompoundEdit("Starting Pri... |
Integer oldPrimaryKeySeq = primaryKeySeq; | public void setPrimaryKeySeq(Integer argPrimaryKeySeq) { // do nothing if there's no change if ( (primaryKeySeq == null && argPrimaryKeySeq == null) || (primaryKeySeq != null && primaryKeySeq.equals(argPrimaryKeySeq)) ) { return; } try { startCompoundEdit("Starting Pri... | |
if (type != argType) { setSourceDataTypeName(null); this.type = argType; fireDbObjectChanged("type",oldType,argType); } | setSourceDataTypeName(null); this.type = argType; fireDbObjectChanged("type",oldType,argType); | public void setType(int argType) { int oldType = type; if (type != argType) { setSourceDataTypeName(null); this.type = argType; fireDbObjectChanged("type",oldType,argType); } } |
System.out.println("Col index "+selectedColIndex); | logger.debug("Col index "+selectedColIndex); | public void mouseClicked(MouseEvent evt) { Point p = evt.getPoint(); unzoomPoint(p); PlayPenComponent c = contentPane.getComponentAt(p); if (c != null) p.translate(-c.getX(), -c.getY()); if ( c instanceof Relationship) { if (evt.getClickCount() == 2) { ArchitectFrame.getMainInstance().editRelationshi... |
ddlg.makeDropForeignKeySQL(c.getCatalog(), c.getSchema(), rs.getString("FKTABLE_NAME"), c.getName())); | ddlg.makeDropForeignKeySQL(rs.getString("FKTABLE_NAME"), c.getName())); | private void addDependantsFromKeys(ResultSet rs) throws SQLException { Conflict prev = null; while (rs.next()) { Conflict c = new Conflict("FOREIGN KEY", rs.getString("FKTABLE_CAT"), rs.getString("FKTABLE_SCHEM"), ... |
c.setSqlDropStatement(ddlg.makeDropTableSQL(c.getCatalog(), c.getSchema(), c.getName())); | ddlg.setTargetCatalog(c.getCatalog()); ddlg.setTargetSchema(c.getSchema()); c.setSqlDropStatement(ddlg.makeDropTableSQL(c.getName())); | public void findConflicting() throws SQLException, ArchitectException { doingFindConflicting = true; Connection con = null; try { conflicts = new ArrayList(); monitorableProgress = 0; if (logger.isDebugEnabled()) { logger.debug("About to find conflicting objects for DDL Script... |
return (Tag) tagHolderMap.get(script); | Tag tag = (Tag) tagHolderMap.get(script); if( tag == null && getParent() != null) { return getParent().getTagOfTagScript(script); } else { return tag; } | public Tag getTagOfTagScript(TagScript script) { if( script == null ) return null; return (Tag) tagHolderMap.get(script); } |
public void run(Context context, XMLOutput output) throws Exception { | public void run(JellyContext context, XMLOutput output) throws Exception { | public void run(Context context, XMLOutput output) throws Exception { tagLibrary = new DynamicTagLibrary( getUri() ); context.registerTagLibrary( getUri(), tagLibrary ); getBody().run(context, output); tagLibrary = null; } |
public DynamicTagLibrary(String uri) { this.uri = uri; | public DynamicTagLibrary() { | public DynamicTagLibrary(String uri) { this.uri = uri; } |
public Vector calcTDT(Vector chromosomes) { int numChroms; Chromosome chromT, chromU,chromTemp; String ped,ind; Vector temp; numChroms = chromosomes.size(); temp = (Vector)chromosomes.clone(); chromosomes = temp; | public static Vector calcTDT(Vector chromosomes) { Vector results = new Vector(); | public Vector calcTDT(Vector chromosomes) { int numChroms; Chromosome chromT, chromU,chromTemp; String ped,ind; Vector temp; numChroms = chromosomes.size(); temp = (Vector)chromosomes.clone(); chromosomes = temp; int numMarkers = Chromosome.getSize(); f... |
this.results.add(new TDTResult(Chromosome.getMarker(k))); | results.add(new TDTResult(Chromosome.getMarker(k))); | public Vector calcTDT(Vector chromosomes) { int numChroms; Chromosome chromT, chromU,chromTemp; String ped,ind; Vector temp; numChroms = chromosomes.size(); temp = (Vector)chromosomes.clone(); chromosomes = temp; int numMarkers = Chromosome.getSize(); f... |
for(int i=0;i<this.results.size();i++){ TDTResult tempRes = (TDTResult)this.results.get(i); | for(int i=0;i<results.size();i++){ TDTResult tempRes = (TDTResult)results.get(i); | public Vector calcTDT(Vector chromosomes) { int numChroms; Chromosome chromT, chromU,chromTemp; String ped,ind; Vector temp; numChroms = chromosomes.size(); temp = (Vector)chromosomes.clone(); chromosomes = temp; int numMarkers = Chromosome.getSize(); f... |
return this.results; | return results; | public Vector calcTDT(Vector chromosomes) { int numChroms; Chromosome chromT, chromU,chromTemp; String ped,ind; Vector temp; numChroms = chromosomes.size(); temp = (Vector)chromosomes.clone(); chromosomes = temp; int numMarkers = Chromosome.getSize(); f... |
getBody().run(context, output); | invokeBody(output); | public void doTag(XMLOutput output) throws Exception { Object obj = getObject(); if ( this.task != null ) { Method method = MethodUtils.getAccessibleMethod( this.task.getClass(), "addText", ... |
String text = expression.getExpressionText(); assertEquals( "Wrong textual representation for expression text: ", expressionText, text); | protected void assertExpression(String expressionText, Object expectedValue) throws Exception { Expression expression = CompositeExpression.parse(expressionText, factory); assertTrue( "Created a valid expression for: " + expressionText, expression != null ); Object value = expression.evaluate(c... | |
ctrl.viewChanged( this, PhotoInfoController.QUALITY ); | if ( getQuality() != null ) { ctrl.viewChanged( this, PhotoInfoController.QUALITY ); } | public void actionPerformed( ActionEvent evt ) { if ( evt.getActionCommand().equals( "save" ) ) { try { ctrl.save(); } catch ( Exception e ) { log.warn( "exception while saving" + e.getMessage() ); e.printStackTrace(); } } else if ( evt.getActionCommand().equals( "discard" ) ) { log.debug( "Disca... |
log.debug( "fuzzyDate = " + str ); | public FuzzyDate getFuzzyDate( ) { String str = fuzzyDateField.getText( ); FuzzyDate d = FuzzyDate.parse( str ); return d; } | |
return photographerField.getText( ); | String str = photographerField.getText( ); return str; | public String getPhotographer( ) { return photographerField.getText( ); } |
return new Integer( qualityField.getSelectedIndex() ); | int q = qualityField.getSelectedIndex(); Integer retval = null; if ( q >= 0 ) { retval = new Integer( q ); } return retval; | public Number getQuality() { return new Integer( qualityField.getSelectedIndex() ); } |
ctrl.viewChanged( this, changedField ); | Object fieldValue = ctrl.getField( changedField ); if ( fieldValue != null || changedDoc.getLength() > 0 ) { ctrl.viewChanged( this, changedField ); } | public void insertUpdate( DocumentEvent ev ) { Document changedDoc = ev.getDocument(); String changedField = (String) changedDoc.getProperty( FIELD_NAME ); ctrl.viewChanged( this, changedField );// // Handle fuzzy time// if ( changedDoc == fuzzyDateDoc ) {// log.warn( "Fuzzy date entered" );// String fd... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.