Create votable from ellipse results
The workflow takes from a votable the names of files where the ellipse result is stored. These files contain data for several ellipses and the workflow takes the center from the inner ellipse and the ellipticitiy from one of the outter ones. It uses astrotaverna plugin (http://wf4ever.github.com/astrotaverna/).
Preview
Run
Run this Workflow in the Taverna Workbench...
Option 1:
Copy and paste this link into File > 'Open workflow location...'
http://myexperiment.org/workflows/3067/download?version=2
[ More Info ]
Taverna is available from http://taverna.sourceforge.net/
If you are having problems downloading it in Taverna, you may need to provide your username and password in the URL so that Taverna can access the Workflow:
Replace http:// in the link above with http://yourusername:yourpassword@
Workflow Components
Julian Garrido |
Create votable from ellipse results |
The workflow takes from a votable the names of files where the ellipse result is stored. These files contain data for several ellipses and the workflow takes the center from the inner ellipse and the ellipticitiy from one of the outter ones. It uses astrotaverna plugin (http://wf4ever.github.com/astrotaverna/). |
None
Name | Description |
---|---|
ColumnNameWithHeaderFile | |
votable | |
ColumnNameWithDataFile |
Name | Type | Description |
---|---|---|
List_from_column | voutils | |
ellipseHeader2asciiHeader | beanshell |
it reads galfit configuration file if its components are: disk, bulb, bar and sky or disk, bulb and sky. Scriptimport java.util.regex.Matcher; import java.util.regex.Pattern; asciiHeader ="#"; // read column names from cat file and add header to resultTable String number = "([-0123456789.]+)"; String word = "(\\w+)"; String expression = word+".*"; // Position x, y Pattern pattern1 = Pattern.compile(expression); Matcher matcher1 = pattern1.matcher(ellipseHeader); //ArrayList values = new ArrayList(); while (matcher1.find()) { String col = matcher1.group(1); //values.add(col); asciiHeader += " " + col.toLowerCase(); } asciiHeader +="\n"; |
List_from_column_2 | voutils | |
Concatenate_two_strings_2 | localworker |
Scriptoutput = string1 + string2; |
Format_conversion | tpipe | |
formatTableIn_value | stringconstant |
Valueascii |
formatTableOut_value | stringconstant |
Valuevotable |
Select_columns | tpipe | |
filter_value | stringconstant |
Valuex0 y0 ellip pa |
List_from_column_3 | voutils | |
X0_column | stringconstant |
Valuex0 |
List_from_column_4 | voutils | |
List_from_column_5 | voutils | |
Y0_column | stringconstant |
Valuey0 |
ELLIP_column | stringconstant |
Valueellip |
lists2ascii | beanshell |
It returns an ascii table that contains one only row.
x0 and y0 are taken from the first element of each list and ellip2 is taken from the n-3 element of the list (being n the size of the list). Scriptasciitable = "# x0 y0 ellip pa \n" + "" + x0.get(0) + " " + y0.get(0) + " " + ellip.get(ellip.size()-3) + " " + pa.get(pa.size()-3); |
Format_conversion_2 | tpipe | |
ascii_value_1 | stringconstant |
Valueascii |
votable_value_1 | stringconstant |
Valuevotable |
Cat_n-tables | tcat | |
tjoin | tjoin | |
MakeDoubleTypes | beanshell |
It replaces float by double types Scriptout = in.replaceAll("float", "double"); |
List_from_column_6 | voutils | |
PA_column | stringconstant |
Valuepa |
Add_Column | tpipe | |
ellip1_not0_value | stringconstant |
Valueellip1_not0 |
expression_value | stringconstant |
Valueellip >= 0.05 ? ellip : 0.05 |
Read_File_1 | beanshell |
Read a header file and if the file does not exists, it returns a default header Scriptimport java.io.BufferedInputStream; import java.io.File; import java.io.FileInputStream; import java.io.IOException; String readFileAsString(String filePath) throws java.io.IOException{ byte[] buffer = new byte[(int) new File(filePath).length()]; BufferedInputStream f = null; try { f = new BufferedInputStream(new FileInputStream(filePath)); f.read(buffer); } finally { if (f != null) try { f.close(); } catch (IOException ignored) { } } return new String(buffer); } try{ string = readFileAsString(filePath); }catch (IOExpception){ string = defaultContent; } |
Read_File_2 | beanshell |
Read a ellipse data file and if the file does not exists, it returns a a ellipse file filled with -999.0 vlaues. Scriptimport java.io.BufferedInputStream; import java.io.File; import java.io.FileInputStream; import java.io.IOException; String readFileAsString(String filePath) throws java.io.IOException{ byte[] buffer = new byte[(int) new File(filePath).length()]; BufferedInputStream f = null; try { f = new BufferedInputStream(new FileInputStream(filePath)); f.read(buffer); } finally { if (f != null) try { f.close(); } catch (IOException ignored) { } } return new String(buffer); } try{ string = readFileAsString(filePath); }catch (IOExpception){ string = defaultContent; } |
defaultDataContent | stringconstant |
Value-999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 -999.0 |
defaultHeader | stringconstant |
ValueSMA R %7.2f pixel INTENS R %10.3g "" INT_ERR R %10.3g "" PIX_VAR R %9.3g "" RMS R %9.3g "" ELLIP R %6.4f "" ELLIP_ERR R %6.4f "" PA R %6.2f degrees PA_ERR R %6.2f degrees X0 R %7.2f pixel X0_ERR R %6.2f pixel Y0 R %7.2f pixel Y0_ERR R %6.2f pixel GRAD R %8.3g "" GRAD_ERR R %6.3g "" GRAD_R_ERR R %6.3g "" RSMA R %7.5f pixel**1/4 MAG R %7.3g "" MAG_LERR R %7.3g "" MAG_UERR R %7.3g "" TFLUX_E R %12.5g "" TFLUX_C R %12.5g "" TMAG_E R %7.3g "" TMAG_C R %7.3g "" NPIX_E I %6d "" NPIX_C I %6d "" A3 R %9.3g "" A3_ERR R %7.3g "" B3 R %9.3g "" B3_ERR R %7.3g "" A4 R %9.3g "" A4_ERR R %7.3g "" B4 R %9.3g "" B4_ERR R %7.3g "" NDATA I %5d "" NFLAG I %5d "" NITER I %3d "" STOP I %2d "" A_BIG R %9.3g "" SAREA R %5.1f pixel |
Select_Rows | tpipe | |
no_error_expression | stringconstant |
Valueellip != -999 |
Name | Description | Inputs | Outputs |
---|---|---|---|
ellipseHeader2asciiHeader | it reads galfit configuration file if its components are: disk, bulb, bar and sky or disk, bulb and sky. | ellipseHeader | asciiHeader |
lists2ascii | It returns an ascii table that contains one only row. x0 and y0 are taken from the first element of each list and ellip2 is taken from the n-3 element of the list (being n the size of the list). |
x0 y0 ellip pa |
asciitable |
MakeDoubleTypes | It replaces float by double types | in | out |
Read_File_1 | Read a header file and if the file does not exists, it returns a default header |
filePath defaultContent |
string |
Read_File_2 | Read a ellipse data file and if the file does not exists, it returns a a ellipse file filled with -999.0 vlaues. |
filePath defaultContent |
string |
Name | Description |
---|---|
VotableWithnewColumns | |
EllipseVotable | |
votable_without_ellipse_failure |
Source | Sink |
---|---|
ColumnNameWithHeaderFile | List_from_column:ColumnName |
votable | List_from_column:voTable |
Read_File_1:string | ellipseHeader2asciiHeader:ellipseHeader |
votable | List_from_column_2:voTable |
ColumnNameWithDataFile | List_from_column_2:ColumnName |
ellipseHeader2asciiHeader:asciiHeader | Concatenate_two_strings_2:string1 |
Read_File_2:string | Concatenate_two_strings_2:string2 |
Concatenate_two_strings_2:output | Format_conversion:voTable |
formatTableIn_value:value | Format_conversion:formatTableIn |
formatTableOut_value:value | Format_conversion:formatTableOut |
Format_conversion:outputTable | Select_columns:voTable |
filter_value:value | Select_columns:filter |
Select_columns:outputTable | List_from_column_3:voTable |
X0_column:value | List_from_column_3:ColumnName |
Select_columns:outputTable | List_from_column_4:voTable |
Y0_column:value | List_from_column_4:ColumnName |
Select_columns:outputTable | List_from_column_5:voTable |
ELLIP_column:value | List_from_column_5:ColumnName |
List_from_column_3:list | lists2ascii:x0 |
List_from_column_4:list | lists2ascii:y0 |
List_from_column_5:list | lists2ascii:ellip |
List_from_column_6:list | lists2ascii:pa |
ascii_value_1:value | Format_conversion_2:formatTableIn |
votable_value_1:value | Format_conversion_2:formatTableOut |
lists2ascii:asciitable | Format_conversion_2:voTable |
MakeDoubleTypes:out | Cat_n-tables:votableList |
votable | tjoin:votable1 |
Add_Column:outputTable | tjoin:votable2 |
Format_conversion_2:outputTable | MakeDoubleTypes:in |
Select_columns:outputTable | List_from_column_6:voTable |
PA_column:value | List_from_column_6:ColumnName |
Cat_n-tables:outputFileOut | Add_Column:voTable |
ellip1_not0_value:value | Add_Column:nameNewCol |
expression_value:value | Add_Column:expression |
List_from_column:list | Read_File_1:filePath |
defaultHeader:value | Read_File_1:defaultContent |
List_from_column_2:list | Read_File_2:filePath |
defaultDataContent:value | Read_File_2:defaultContent |
tjoin:outputFileOut | Select_Rows:voTable |
no_error_expression:value | Select_Rows:filter |
tjoin:outputFileOut | VotableWithnewColumns |
Add_Column:outputTable | EllipseVotable |
Select_Rows:outputTable | votable_without_ellipse_failure |
None
Workflow Type
Version 2 (latest) (of 2)
- astronomy
- |
- astrotaverna
- |
- ellipse
- |
- iraf
- |
- pyraf
- |
- sextractor
- |
- votable
- astronomy
- |
- astrotaverna
- |
- ellipse
- |
- iraf
- |
- pyraf
- |
- sextractor
- |
- votable
Log in to add Tags
Shared with Groups (0)
None
Statistics
In chronological order:
-
Created by Julian Garrido on Tuesday 07 August 2012 09:21:18 (UTC)
Last edited by Julian Garrido on Tuesday 07 August 2012 09:24:29 (UTC)
-
Created by Julian Garrido on Friday 07 September 2012 13:20:02 (UTC)
Reviews (0)
Other workflows that use similar services (0)
There are no workflows in myExperiment that use similar services to this Workflow.
Comments (0)
No comments yet
Log in to make a comment