Description Usage Arguments Value
This function takes the Q$stateActionPair
dataframe initialized in the
background and filters it to pull the Q-table index that matches the
state-action pair. It then updates the Q-value according to the Q-learning
algorithm.
1 | updateQsecondState(state, action, alpha, gamma)
|
state |
The state the agent is currently in. |
action |
The action (right or left) an agent performs. |
alpha |
The learning rate alpha. |
gamma |
The temporal discounting factor gamma. |
Updated second state Q-value
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.