
Ask HN: I get headaches. What sensors can I get to collect data about them? - Ian999
Hi, I work in quant finance and spend a lot of time with data. I also get headaches 3-4 times a week. I would like to collect data on myself with various sensors. I know there are simple things like a fitbit to collect data but how can I discover what other data I can collect?
======
oblib
I used to get headaches too. I finally figured out it was three things that
would get me. Being dehydrated, exposure to perfumes, colognes and other
scented household stuff like cleaner solutions, and the 3rd was industrial and
household solvents like lacquer thinner and acetone (fingernail polish
remover).

It took me years to figure that out. Perfumes and scents are so pervasive
they're easy to ignore as a trigger for headaches but they get to me fast and
the headaches last a long time.

I avoid that stuff like poison now. I will leave the area if I detect it.

Getting outside and breathing fresh air always cured the headaches from
perfumes and solvents. It was the only thing that did get rid of them. Over
the counter meds did nothing for me.

I use an activated charcoal filter on my tap water now and that makes drinking
water a pleasure again. And I pay closer attention to not letting myself get
dehydrated. It's easy to tell, I just press a fingertip and if it leaves a
dent I need water even if I don't "feel" thirsty.

So, if these are what's causing your headaches you need to be proactive to
prevent them and to get rid of them, and a "fitbit" won't help much with
figuring out the cause.

------
vinchuco
Instead of logging data, I'd suggest debugging for root causes. Regardless of
approach, items:

Hydration. Eye-strain. Sleep. Exercise. Stress. Etc.
[https://en.wikipedia.org/wiki/Migraine#Cause](https://en.wikipedia.org/wiki/Migraine#Cause)

Meta: we seem obsessed about data and we have standard techniques for
exploring relationships between them, but what is the equivalent source of
techniques for first-principle root-cause search? (In the more practical, not
the philosophical* sense)

* [https://plato.stanford.edu/entries/causation-metaphysics/](https://plato.stanford.edu/entries/causation-metaphysics/)

------
Broken_Hippo
I don't personally get headaches that often, but my mother and sister both do.
My mother gets cluster headaches - tension headaches plus migraines, normal
headaches, and sinus headaches on top of it. My sister gets migraines.
Extended family has also been plagued. I fully urge you to figure out the root
cause and seek medical help. I don't know if sensors will help with some
(most) of these.

I fully suggest keeping track of when you get headaches, including what you
were doing when you noticed it. Might keep track of daily activities as well.

The following are things that I know can trigger headaches. Obviously not all-
inclusive:

1\. Poor eyesight or other eye strain. Normal folks will get eye strain
reading too-small text or staring at a computer screen. 2\. Stress, anxiety,
or depression: The muscles tense up, causing headaches. Massages help my
mother, as do muscle relaxers and/or anti-anxiety medicine. 3\. Sinus problems
and/or allergies. 4\. Dental problems. 5\. Scents from various things or
chemicals 6\. Lack of sleep, sleep apnea, or other sleeping issues 7\. High
blood pressure (pharmacies and wal-marts often have machines to test, and I'd
test often for a few weeks) 8\. Food sensitivities 9\. Neck strain (posture or
medical). 10\. Dehydration (easy to check) 11\. Changes in weather. 12\.
Random viral or bacterial infections. 13\. Low vitamin D. I personally had
this happen, among other things. 14\. Smoking or living with a smoker 15\. Dry
nasal cavities. You can use a saline nasal spray for this. I recommend
disposables since they are sterile each time you open them (less chance of
mold, etc). 16. Hormones. This might be more for women, especially with PMS
and/or menopause. I'm not sure how it happens in men.

------
cryptoz
A lot of phones have a barometer in them. New iPhones do and most Androids do.
Log the data on a 1-minute interval, understand that the data is noisy and the
noise comes from moving elevation. Watch the graphs over 1-hour, 6-hours,
12-hour, 2-day timeframes. You'll see rises and peaks and you might note
headache timing with a peak or a trough. Migraines happen to a lot of people
and can be triggered by sudden changes in pressure. Not sure about your
headaches but it's a start.

~~~
Ian999
That’s great. I’d like to collect all sorts of data because it’s unclear what
the triggers could be. Thank you.

------
godot
I'm very prone to headaches and migraines as well and after a couple of
decades of observations, I've nailed down the root causes pretty well for
myself. This doesn't answer your question for logging data but it's some
things you could look into.

1\. Hydration - a main contributing factor in almost every episode of migraine
I get. If I go for prolonged periods without water (as in, a couple of hours),
it can start. This has really only gotten worse/more prone as I got older. I
need to keep drinking water more frequently than when I was younger to keep
off migraines. The funny thing is, if I want to sleep in on the weekends, I
have to make sure to drink some water when I wake up at 7~8, before I go back
to sleep. Otherwise, I wake up after sleeping for 10 hours with a migraine.

2\. Sleep time - as I got older, I became intolerant of "elastic" sleep hours.
I pretty much have to keep to a fairly consistent sleep schedule daily
(varying no more than an hour off a day). If I go to bed an hour or 1.5 hours
late for a day, my chances of getting a migraine the next day is very high.
(could be reduced if I drink even more water than usual that night; see
previous point)

3\. Screen color - Use an automatic blue light reducer software like f.lux for
your OS, whichever you use. Even better, install it on mobile too. This made a
noticeable difference when I first started using it.

4\. Screen use when unfocused - this one is funny and might be unique to
myself. I find that when I'm bored and just surfing the web (like reading HN
right now), I start getting migraines after a longer period of it (an hour or
two). If I'm actually working, writing code, etc. I have no problems looking
at the screen for hours on end. I don't really know why this is, but I have
pretty much confirmed this to be the case myself.

5\. Gaming - less of a factor nowadays simply because I don't game much
anymore. I used to play games like SC Brood War, Diablo 2, WoW for hours on
end and be OK when I was younger. Now, if I play Starcraft 2 or HotS for more
than an hour, the migraines start.

------
mathieubordere
I too get headaches. I'm only certain about two causes in my case.

\- Alcohol: If I drink even 1 glass of alcohol there's a good chance I'll wake
up with a nasty migraine. In my case this means pretty much banning alcohol
out of my life except for special occasions (to let some steam off ...)

\- Exercise: This one is a bit nasty, I feel great just after exercising, but
12h later there's a good chance I'll have a migraine.

------
bb88
Caffeine is the number one cause of headaches. It causes the arteries to
constrict, lowering blood flow to the brain.

Other than that, there's lots of things that can be measured.

1\. Sleep.

Fit bit will work, but more importantly is a pulse oximiter that measures
oxygen intake through the night. If you're not sleeping well, apnea may be
causing your headaches. You would see this by an oxygen drop below 88. This
will cause your heart to race as well throughout the night as it has to work
harder to push oxygen through your body.

Also, it's worth noting that it's not heavyweight people that experience
apnea. It can happen with anyone and with any weight.

Some watches have oximeters built in I believe. This really needs to be done
for one night, and if something is wrong, you should go see a sleep doctor
anyway.

2\. Caffiene / Sugar intake

This can be simple script that when you drink caffiene/sugar you just run a
script that logs the time/date and amount to a google doc. Also you can use
this to track your headaches. If you get headaches during a particular time of
day, then it could be intake related.

3\. Exercise

Your cellphone/smart watch can measure steps, as can a fit/bit, etc. 10,000
steps a day is the recommended amount of exercise for people that don't get a
lot of exercise in.

4\. Feelings / Stress

So seratonin regulates your feelings. Ideally, if you're feeling sad, angry,
or stressed, or down, you should feel those for a while and then your feelings
should return to normal over time. If you're feeling emotionally bad all the
time, you can get your seratonin level checked through a blood test.

5\. Eye strain

60 hertz flickering lights, bad eyesight, are all causes of eye strain.

Here's an article which talks about detecting flicker.

[https://www.graybar.com/applications/lighting/blog/the-
flick...](https://www.graybar.com/applications/lighting/blog/the-flicker-
checker-on-smartphone)

If you have a friend with a D850 camera, that camera can detect flicker and
report it through the viewfinder.

6\. Blood pressure.

A blood pressure cuff is a good thing here. $30 or so. Take your blood
pressure once a day and record the readings. And take your blood pressure when
the headaches arrive.

7\. Salt intake.

So salt increases blood pressure, so one option is to watch how much salt you
eat in your diet, and if you're salting food constantly, cut back. Or drink
more water to help flush the salt out of your system.

There's a sodium tracker here in a pdf, but you could just as well make a
google doc out of it:

[http://www.heart.org/idc/groups/heart-
public/@wcm/@fc/docume...](http://www.heart.org/idc/groups/heart-
public/@wcm/@fc/documents/downloadable/ucm_448279.pdf)

8\. Energy Drinks.

These should probably be avoided at all costs. But if you're hooked and feel
like you need them, just record when you drink one. The key is not to make you
feel bad about drinking them if your hooked, but making you aware that when
you're drinking them.

~~~
hanniabu
> 60 hertz flickering lights, bad eyesight, are all causes of eye strain.

If that's the case, it's funny we would choose to use 60fps for games.
Shouldn't that have a similar affect with flickering between scenes? Or
actually I guess the new scene replaces the old scene rather than going dark
in between like what happens with a flickering light

~~~
bb88
Apologies for not seeing your post until just now.

Back in the day, The multi-sync CRT's would sync VBLANK[1] to the power line
if the screen was at 60hz. If a fluorescent tube overhead was also 60hz, the
flicker became unavoidable and caused many an office worker a migraine
headache. To avoid this issue, graphics cards and monitors started syncing at
85hz.

With an LCD panel at 60hz, the backlight is not flickering, and the screen
itself is not vanishing off the display like it is on the CRT.

The reason to use 120hz and higher these days is to prevent motion blur. [2]

[1]
[https://en.wikipedia.org/wiki/Vertical_blanking_interval](https://en.wikipedia.org/wiki/Vertical_blanking_interval)

[2] [https://www.cnet.com/news/ultra-hd-4k-tv-refresh-
rates/](https://www.cnet.com/news/ultra-hd-4k-tv-refresh-rates/)

