Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

natspec(TabLib): Improved Documentation for _calculateTab #168

Merged
merged 2 commits into from
Oct 6, 2021

Conversation

kamescg
Copy link
Contributor

@kamescg kamescg commented Oct 5, 2021

No description provided.

@kamescg kamescg added the documentation Improvements or additions to documentation label Oct 5, 2021
@kamescg kamescg self-assigned this Oct 5, 2021
@@ -247,8 +247,20 @@ library TwabLib {
return differenceInAmount / differenceInTime;
}

/// @notice Calculates the TWAB for a given timestamp. It interpolates as necessary.
/// @param _twabs The TWAB history
/** @notice Calculates a user TWAB for a target timestamp using the historical TWAB list.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would add that it linearly interpolates a twab using the TWAB history.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes sir.

@asselstine asselstine merged commit 21a38cc into master Oct 6, 2021
@asselstine asselstine deleted the pool-1682-twablib-_calculatetwab-should-be branch October 6, 2021 02:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants