public ChiSquare GetSatisfiedAndNoSatisfiedDictionary(string demographic, int test_id, string type, double pValue, int?FO_id) { Test test = new TestsServices().GetById(test_id); ChiSquare chiSquare = new ChiSquare(test, demographic, null, null, null, null, FO_id, pValue, null, null, null); chiSquare.GetAssociation(); return(chiSquare); }
public ChiSquare getChiSquare(int test_id, string Demographic, int?questionnaire_id, int?category_id, int?question_id, int?country_id, int?FO_id, double?pValue) { ChiSquare chiSquare; double pvalue; if (pValue.HasValue) { pvalue = pValue.Value; } else { pvalue = 0.05; } chiSquare = new ChiSquare(new TestsServices().GetById(test_id), Demographic, questionnaire_id, category_id, question_id, country_id, FO_id, pvalue, null, null, null); chiSquare.GetAssociation(); return(chiSquare); }
private void GetConclusion(List <string> demographicsWithAssociation, ChiSquare cs, string demographic, string name) { Dictionary <string, double> sat = (Dictionary <string, double>)cs.DataSatisfaction["Satisfied"];//diccionario de satisfechos y no satisfechos if (sat.Count > 1) { cs.GetAssociation();//aqui realmente realiza lo de chicuadrado y trae los valores de:la tabla, de nosotros y la conclusion } if (cs.Association) { if (demographic == "FunctionalOrganizationType") { demographicsWithAssociation.Add(name);//agreega el nombre de la estructura funcional o el nombre del demografico } else { demographicsWithAssociation.Add(DemographicNames[demographic]); } } }