#import <AgentStats.h>
Public Member Functions | |
(void) | - addEpisodeWithLength:andActions:learningMode: |
(void) | - addEpisode |
(int) | - averageTimeLearning |
(int) | - averageTimeNonLearning |
(int) | - averageActionsLearning |
(int) | - averageActionsNonLearning |
(int) | - episodesCompleted |
(void) | - clearTempData |
Static Public Member Functions | |
(AgentStats *) | + sharedAgentStats |
Protected Attributes | |
int | episodesCompleted |
CCArray * | learningLengths |
CCArray * | nonLearningLengths |
CCArray * | learningActions |
CCArray * | nonLearningActions |
Definition at line 13 of file AgentStats.h.
- (void) addEpisode |
Increments the episode counter
Definition at line 88 of file AgentStats.m.
- (void) addEpisodeWithLength: | (int) | _time | |
andActions: | (int) | _actions | |
learningMode: | (BOOL) | _learning | |
Adds an episode to the correct array for later analysis
time | taken |
actions | performed |
whether | still learning |
Definition at line 99 of file AgentStats.m.
- (int) averageActionsLearning |
Calculates the average actions taken when learning
Definition at line 149 of file AgentStats.m.
- (int) averageActionsNonLearning |
Calculates the average actions taken when not learning
Definition at line 163 of file AgentStats.m.
- (int) averageTimeLearning |
Calculates the average of all of the learning times
Definition at line 121 of file AgentStats.m.
- (int) averageTimeNonLearning |
Calculates the average of all of the non-learning times
Definition at line 135 of file AgentStats.m.
- (void) clearTempData |
Resets the temporary variables
Definition at line 184 of file AgentStats.m.
- (int) episodesCompleted |
+ (AgentStats *) sharedAgentStats |
- (int) episodesCompleted [protected] |
Returns how many episodes have been completed
Definition at line 16 of file AgentStats.h.
- (CCArray*) learningActions [protected] |
Definition at line 19 of file AgentStats.h.
- (CCArray*) learningLengths [protected] |
Definition at line 17 of file AgentStats.h.
- (CCArray*) nonLearningActions [protected] |
Definition at line 20 of file AgentStats.h.
- (CCArray*) nonLearningLengths [protected] |
Definition at line 18 of file AgentStats.h.