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

After clicking thru 3 links I still don't know how to us it #9

Open
xiaodaigh opened this issue Sep 5, 2019 · 3 comments
Open

After clicking thru 3 links I still don't know how to us it #9

xiaodaigh opened this issue Sep 5, 2019 · 3 comments

Comments

@xiaodaigh
Copy link

How about some simple examples in the readme?

@nviraj
Copy link

nviraj commented Aug 23, 2020

It's pretty convenient actually.
Just came across this randomly when I was looking at the repo. For people looking for it in the future, here is an example.

library("tictoc")

tictoc::tic("Multiplying 2 numbers")
a <- 5698
b <- 67335
c <- a * b

tictoc::tic("Running a for loop in between to demonstrate nested tictoc")

for(i in base::seq(from = 0, to = 1000, by = 10)) {
print(i)
}

tictoc::toc()

message(c)

tictoc::toc()

@xiaodaigh
Copy link
Author

Why not just put that in the github readme?

@nviraj
Copy link

nviraj commented Aug 23, 2020

Not the author of the package, but in their defense, examples are present in both the help section accessed through ?tictoc::tic and package documentation on CRAN

But you might be right that the utility of the package and it's functions can also be present in readme for people coming across this package through github as compared to other sources.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants