PanelStatistics class

From Catglobe Wiki
Jump to: navigation, search

PanelStatistics



The panel statistics collection. To view information like how big a panel is, how it is used etc.

Parent class

Inherits from object

Constructors

  • (array questionnaireResourceTemplateRId "Restricts the questionnaires examined to these types of questionnaires", array bulkmailResourceTemplateRId "Restricts the count of mails sent to those sent from these types of bulkmail", int groupRId "Resource id of group containing all panel members", array from "From date", array to "To date", int groupBy "Return results in these groupings. -1=Total, 0=day, 1=Week, 2=Month, 3=Quarter, 4=Year", int panelCreationQuestionnaireResourceId "If >0 then the endodate of qas in this questionnaire is used for creation date, otherwise the user created date is used") - Create new statistics

Methods

  • array CountActive() - Number of panel members that started a qas.
  • array CountCompletedInterviews() - Number of panel members that completed a qas.
  • array CountCompletedInterviewsWithPoints() - Number of panel members that completed a qas that gave them points.
  • array CountCreated() - Number of panel members that was created.
  • array CountDisabled() - Number of panel members that was disabled.
  • array CountEarnedPoints() - Number of points panel members earned
  • array CountGotInvitation() - Number of panel members that received an invitation.
  • array CountPointsOfType(int type "Type of transaction: 0 for manual/scripted, 1 for orders, 2 for questionnaire, 3 for visitorsite, 4 for expired, negative for custom.") - Number of points panel members used of a given type.
  • array CountReadInvitation() - Number of panel members that read an invitation. This number depends on emails using the tracking feature, and is thus subject to same inaccuracy.
  • array CountReadInvitationSum() - Number times an invitation was read. This number depends on emails using the tracking feature, and is thus subject to same inaccuracy.
  • array CountTotal() - The number of panel members excluding disabled and deleted.
  • array CountUsedPoints() - Number of points panel members used. Included points spent on shopping and subtracted for going back in a questionnaire.
  • array CountUsedPointsOnOrders() - Number of points panel members used for shopping.
  • Dictionary of numbers DetailsActive() - Panel members started how many qas.
  • Dictionary of numbers DetailsCompletedInterviews() - Panel members completed how many qas.
  • Dictionary of numbers DetailsCompletedInterviewsWithPoints() - Panel members completed how many qas where each gave them some points.
  • Dictionary of numbers DetailsCreated() - Panel members that was created.
  • Dictionary of numbers DetailsDisabled() - Panel members that was disabled.
  • Dictionary of numbers DetailsGotInvitation() - Panel members receive how many invitations.
  • Dictionary of numbers DetailsPointsOfType(int type "Type of transaction: 0 for manual/scripted, 1 for orders, 2 for questionnaire, 3 for visitorsite, 4 for expired, negative for custom.") - Number of points panel members used of a given type.
  • Dictionary of numbers DetailsReadInvitation() - Panel members read how many invitations. This number depends on emails using the tracking feature, and is thus subject to same inaccuracy.
  • Dictionary of numbers DetailsReadInvitationSum() - Panel members read how many invitations. This number depends on emails using the tracking feature, and is thus subject to same inaccuracy.
  • array GetGroupings() - The grouping values. E.g. week 32 in 2014 is returned as {32,2014}. Grouping by year is returned as {2014,2014}
  • (From object) string ToString() - The string representation of the object.
  • number TotalAvailablePoints() - Sum of points panel members has available at the 'to' date
  • number TotalEarnedPoints() - Sum of points panel members earned
  • Dictionary of numbers TotalEarnedPointsBySurvey() - Dictionary of questionnaire id and number of points panel members earned for that questionnaire
  • number TotalUsedPoints() - Sum of points panel members used

Properties

  • string ObjectTypeName { get; } - The name of the type of object.
  • (From object) TypeInformation TypeInformation { get; } - Get information about this class.

Examples

array a = DateTime_getByYMD(2014,12,24); array b = DateTime_getByYMD(2015,12,24);

PanelStatistics panel=new PanelStatistics({45592},{2066},69441,a,b,1);

array CountActive=panel.CountActive();// - Number of panel members that started a survey.

array CountCompletedInterviews=panel.CountCompletedInterviews();// - Number of panel members that completed a survey.

array CountCreated=panel.CountCreated();// - Number of panel members that was created.

array CountDisabled=panel.CountDisabled()// - Number of panel members that was disabled.

array CountGotInvitation=panel.CountGotInvitation();// - Number of panel members that received an invitation.

array CountReadInvitation=panel.CountReadInvitation();// - Number of panel members that read an invitation. This number depends on emails using the tracking feature, and is thus subject to same inaccuracy.

array CountTotal=panel.CountTotal();// - The number of panel members including disabled.

array GetGroupings=panel.GetGroupings();// - The groping values. E.g. week 32 in 2014 is returned as {32,2014}. Grouping by year is returned as {2014,2014}

string ToString=panel.ToString();// - The string representation of the object.
//CountReadInvitation & CountReadInvitationSum
array a = DateTime_getByYMD(2017,5,29); 
array b = DateTime_getByYMD(2017,5,31);
PanelStatistics ps = new PanelStatistics({12784},{12767},13900,a,b,1,0);
print(ps.CountReadInvitation());//{3}
print(ps.CountReadInvitationSum());//{9}

Ta.png