Choose Language Hide Translation Bar
Highlighted
Sburel
Level III

Unable to load a list of columns to conduct a Contingency analysis

hello,

 

I want to run a contingency analysis. I have a list of column names (annotationls) to use for Y. Unfortunately with the (wrong) synthax I'm using only the first column name is read and the rest is ignored.

 

The rest of the script is working well.

 

Any suggestions to correct the synthax would be appreciated.

 

thanks

 

Sebastien

 

annotationls = {Name("N(BDNF signaling pathway)"), Name("N(Cross-presentation of particulate exogenous antigens (phagosomes))"), Name("N(Immune system)"), Name("N(Inflammasomes)"), Name("N(Inflammatory response pathway)"), Name("N(Innate immune system)"), Name("N(Integrin alpha-2b beta-3 signaling)"), Name("N(Integrin beta-2 pathway)"), Name("N(Integrin beta-4 pathway)"), Name("N(Integrin beta-5 pathway)"), Name("N(Integrin cell surface interactions)"), Name("N(Integrin family cell surface interactions)"), Name("N(Integrin signaling pathway)"), Name("N(Integrin-linked kinase signaling)"), Name("N(Integrin-mediated cell adhesion)")};

modulals = {Name("Modulation - Abs(Fold change)> 1.5 & LogWorth Adj pvalue> 0.01")};
d={"test_article"};
u={"specimen_material_type"};

DGEsum = Data Table( "summary of DGE" );

enrich=DGEsum<<contingency	(
	Y( column(annotationls)),
	X(column(modulals)),
	by(column(d),column(u)),
	Contingency Table( 0 ),
	mosaic plot(0),
	Tests( 1 ),
);
enrich<<make into combined table("test");

Report( enrich[1] )[Outline Box( "Tests" )][Table Box( 3 )] <<
Make Combined Data Table;
Report( enrich[1] ) << Close Window;
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
txnelson
Super User

Re: Unable to load a list of columns to conduct a Contingency analysis

You will want to use the Eval() function to expand the input lists.

names default to here(1);

annotationls = {Name("N(BDNF signaling pathway)"), 
	Name("N(Cross-presentation of particulate exogenous antigens (phagosomes))"), 
	Name("N(Immune system)"), Name("N(Inflammasomes)"), 
	Name("N(Inflammatory response pathway)"), 
	Name("N(Innate immune system)"),
	Name("N(Integrin alpha-2b beta-3 signaling)"), 
	Name("N(Integrin beta-2 pathway)"), 
	Name("N(Integrin beta-4 pathway)"), 
	Name("N(Integrin beta-5 pathway)"), 
	Name("N(Integrin cell surface interactions)"), 
	Name("N(Integrin family cell surface interactions)"), 
	Name("N(Integrin signaling pathway)"), 
	Name("N(Integrin-linked kinase signaling)"), 
	Name("N(Integrin-mediated cell adhesion)")
};

modulals = {Name("Modulation - Abs(Fold change)> 1.5 & LogWorth Adj pvalue> 0.01")};
d={"test_article"};
u={"specimen_material_type"};

byList = d||u;

DGEsum = Data Table( "summary of DGE" );

enrich=DGEsum<<contingency	(
	Y( eval(annotationls)),
	X(eval(modulals)),
	by(eval(byList),
	Contingency Table( 0 ),
	mosaic plot(0),
	Tests( 1 ),
);
enrich<<make into combined table("test");

Report( enrich[1] )[Outline Box( "Tests" )][Table Box( 3 )] <<
Make Combined Data Table;
Report( enrich[1] ) << Close Window;
Jim

View solution in original post

1 REPLY 1
Highlighted
txnelson
Super User

Re: Unable to load a list of columns to conduct a Contingency analysis

You will want to use the Eval() function to expand the input lists.

names default to here(1);

annotationls = {Name("N(BDNF signaling pathway)"), 
	Name("N(Cross-presentation of particulate exogenous antigens (phagosomes))"), 
	Name("N(Immune system)"), Name("N(Inflammasomes)"), 
	Name("N(Inflammatory response pathway)"), 
	Name("N(Innate immune system)"),
	Name("N(Integrin alpha-2b beta-3 signaling)"), 
	Name("N(Integrin beta-2 pathway)"), 
	Name("N(Integrin beta-4 pathway)"), 
	Name("N(Integrin beta-5 pathway)"), 
	Name("N(Integrin cell surface interactions)"), 
	Name("N(Integrin family cell surface interactions)"), 
	Name("N(Integrin signaling pathway)"), 
	Name("N(Integrin-linked kinase signaling)"), 
	Name("N(Integrin-mediated cell adhesion)")
};

modulals = {Name("Modulation - Abs(Fold change)> 1.5 & LogWorth Adj pvalue> 0.01")};
d={"test_article"};
u={"specimen_material_type"};

byList = d||u;

DGEsum = Data Table( "summary of DGE" );

enrich=DGEsum<<contingency	(
	Y( eval(annotationls)),
	X(eval(modulals)),
	by(eval(byList),
	Contingency Table( 0 ),
	mosaic plot(0),
	Tests( 1 ),
);
enrich<<make into combined table("test");

Report( enrich[1] )[Outline Box( "Tests" )][Table Box( 3 )] <<
Make Combined Data Table;
Report( enrich[1] ) << Close Window;
Jim

View solution in original post

Article Labels