Skip to content

Instantly share code, notes, and snippets.

@barsv
Last active July 2, 2024 20:23
Show Gist options
  • Save barsv/f61b954dd9df834ba5328b87298df6df to your computer and use it in GitHub Desktop.
Save barsv/f61b954dd9df834ba5328b87298df6df to your computer and use it in GitHub Desktop.
MicroStrategy Bitcoin Purchase History
//@version=4
// data source: https://bitcointreasuries.com/microstrategy/
study("MicroStrategy Bitcoin Purchase History", overlay=true)
x = if time > timestamp(2024, 6, 20, 0, 0) and time < timestamp(2024, 6, 21, 0, 0)
11931
else if (time > timestamp(2024, 4, 1, 0, 0) and time < timestamp(2024, 4, 2, 0, 0))
164
else if (time > timestamp(2024, 3, 19, 0, 0) and time < timestamp(2024, 3, 20, 0, 0))
9245
else if (time > timestamp(2024, 3, 11, 0, 0) and time < timestamp(2024, 3, 12, 0, 0))
12000
else if (time > timestamp(2024, 2, 26, 0, 0) and time < timestamp(2024, 2, 27, 0, 0))
3000
else if (time > timestamp(2024, 2, 6, 0, 0) and time < timestamp(2024, 2, 7, 0, 0))
850
else if (time > timestamp(2023, 12, 27, 0, 0) and time < timestamp(2023, 12, 28, 0, 0))
14620
else if (time > timestamp(2023, 11, 30, 0, 0) and time < timestamp(2023, 12, 1, 0, 0))
16130
else if (time > timestamp(2023, 11, 1, 0, 0) and time < timestamp(2023, 11, 2, 0, 0))
155
else if (time > timestamp(2023, 9, 24, 0, 0) and time < timestamp(2023, 9, 25, 0, 0))
5445
else if (time > timestamp(2023, 7, 1, 0, 0) and time < timestamp(2023, 8, 1, 0, 0))
467
else if (time > timestamp(2023, 4, 29, 0, 0) and time < timestamp(2023, 6, 27, 0, 0))
12333
else if (time > timestamp(2023, 4, 5, 0, 0) and time < timestamp(2023, 4, 6, 0, 0))
1045
else if (time > timestamp(2023, 3, 27, 0, 0) and time < timestamp(2023, 3, 28, 0, 0))
6455
else if (time > timestamp(2022, 12, 24, 0, 0) and time < timestamp(2022, 12, 25, 0, 0))
810
else if (time > timestamp(2022, 12, 22, 0, 0) and time < timestamp(2022, 12, 23, 0, 0))
-704
else if (time > timestamp(2021, 11, 1, 0, 0) and time < timestamp(2022, 12, 21, 0, 0))
2395
else if (time > timestamp(2022, 9, 20, 0, 0) and time < timestamp(2022, 9, 21, 0, 0))
301
else if (time > timestamp(2022, 6, 28, 0, 0) and time < timestamp(2022, 6, 29, 0, 0))
480
else if (time > timestamp(2022, 2, 15, 0, 0) and time < timestamp(2022, 4, 5, 0, 0))
4167
else if (time > timestamp(2022, 1, 1, 0, 0) and time < timestamp(2022, 1, 31, 0, 0))
660
else if (time > timestamp(2021, 12, 30, 0, 0) and time < timestamp(2021, 12, 31, 0, 0))
1914
else if (time > timestamp(2021, 11, 29, 0, 0) and time < timestamp(2021, 12, 8, 0, 0))
1434
else if (time > timestamp(2021, 11, 28, 0, 0) and time < timestamp(2021, 11, 29, 0, 0))
7002
else if (time > timestamp(2021, 9, 13, 0, 0) and time < timestamp(2021, 9, 14, 0, 0))
8957
else if (time > timestamp(2021, 6, 21, 0, 0) and time < timestamp(2021, 6, 22, 0, 0))
13005
else if (time > timestamp(2021, 5, 18, 0, 0) and time < timestamp(2021, 5, 19, 0, 0))
229
else if (time > timestamp(2021, 5, 13, 0, 0) and time < timestamp(2021, 5, 14, 0, 0))
271
else if (time > timestamp(2021, 4, 5, 0, 0) and time < timestamp(2021, 4, 6, 0, 0))
253
else if (time > timestamp(2021, 3, 12, 0, 0) and time < timestamp(2021, 3, 13, 0, 0))
262
else if (time > timestamp(2021, 3, 5, 0, 0) and time < timestamp(2021, 3, 6, 0, 0))
205
else if (time > timestamp(2021, 3, 1, 0, 0) and time < timestamp(2021, 3, 2, 0, 0))
328
else if (time > timestamp(2021, 2, 24, 0, 0) and time < timestamp(2021, 2, 25, 0, 0))
19452
else if (time > timestamp(2021, 2, 2, 0, 0) and time < timestamp(2021, 2, 3, 0, 0))
295
else if (time > timestamp(2021, 1, 22, 0, 0) and time < timestamp(2021, 1, 23, 0, 0))
314
else if (time > timestamp(2020, 12, 21, 0, 0) and time < timestamp(2020, 12, 22, 0, 0))
29646
else if (time > timestamp(2020, 12, 4, 0, 0) and time < timestamp(2020, 12, 5, 0, 0))
2574
else if (time > timestamp(2020, 9, 14, 0, 0) and time < timestamp(2020, 9, 15, 0, 0))
16796
else if (time > timestamp(2020, 8, 11, 0, 0) and time < timestamp(2020, 8, 12, 0, 0))
21454
else
na
plotarrow(series=x, colorup=color.teal, colordown=color.orange, transp=40)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment