Cosine vector space
Created: 2010-12-08 11:35:18
Last updated: 2011-01-11 12:05:41
This workflow calculates the cosine vector space between two sets of corpora. The workflow then removes any null values from the output. this is some extra text vbeing added
Preview
Run
Run this Workflow in the Taverna Workbench...
Workflow Components
Authors (1)
Titles (1)
Descriptions (1)
This workflow calculates the cosine vector space between two sets of corpora. The workflow then removes any null values from the output. this is some extra text vbeing added |
Dependencies (0)
Inputs (3)
Name |
Description |
query_abstracts |
|
phenotype_terms |
|
phenotype_term_counts |
|
Processors (5)
Name |
Type |
Description |
regex |
stringconstant |
Value\n\n |
cosine_vector_space |
soaplab |
Endpointhttp://phoebus.cs.man.ac.uk:1977/axis/services/text_mining.cosine_vector_space |
remove_Nulls |
beanshell |
ScriptString[] split = input.split("\n");
Vector nonEmpty = new Vector();
for (int i = 0; i < split.length; i++){
if (!(split[i].equals("")))
{
nonEmpty.add(split[i].trim());
}
}
String[] non_empty = new String[nonEmpty.size()];
for (int i = 0; i < non_empty.length; i ++)
{
non_empty[i] = nonEmpty.elementAt(i);
}
String output = "";
for (int i = 0; i < non_empty.length; i++)
{
output = output + (String) (non_empty[i] + "\n");
} |
split_by_regex |
localworker |
ScriptList split = new ArrayList();
if (!string.equals("")) {
String regexString = ",";
if (regex != void) {
regexString = regex;
}
String[] result = string.split(regexString);
for (int i = 0; i < result.length; i++) {
split.add(result[i]);
}
}
|
merge_cosine_scores |
localworker |
ScriptString seperatorString = "\n";
if (seperator != void) {
seperatorString = seperator;
}
StringBuffer sb = new StringBuffer();
for (Iterator i = stringlist.iterator(); i.hasNext();) {
String item = (String) i.next();
sb.append(item);
if (i.hasNext()) {
sb.append(seperatorString);
}
}
concatenated = sb.toString();
|
Beanshells (1)
Name |
Description |
Inputs |
Outputs |
remove_Nulls |
|
input
|
output
|
Outputs (1)
Name |
Description |
cosine_vector_scores |
|
Datalinks (8)
Source |
Sink |
split_by_regex:split |
cosine_vector_space:pathway_abstracts_direct_data |
phenotype_term_counts |
cosine_vector_space:phenotype_term_count_direct_data |
phenotype_terms |
cosine_vector_space:phenotype_terms_direct_data |
merge_cosine_scores:concatenated |
remove_Nulls:input |
regex:value |
split_by_regex:regex |
query_abstracts |
split_by_regex:string |
cosine_vector_space:output |
merge_cosine_scores:stringlist |
remove_Nulls:output |
cosine_vector_scores |
Uploader
License
All versions of this Workflow are
licensed under:
Version 2 (latest)
(of 2)
Credits (1)
(People/Groups)
Attributions (1)
(Workflows/Files)
Shared with Groups (2)
Featured In Packs (0)
None
Log in to add to one of your Packs
Attributed By (3)
(Workflows/Files)
Favourited By (1)
Statistics
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