Every year, tens of millions of Americans toss and turn with chronic sleep disorders. But diagnosis isn’t easy: It usually means sleeping in a lab entangled in gadgets that track breathing, heart rate, movement, and brain activity, followed by expert analysis of the data. Now, a new technique that uses machine learning and radio signals can get rid of the sleep lab—and the expert. First, an in-home device bounces radio waves—similar to those in cellphones and Wi-Fi routers—off the sleeper, measuring the returning signal. Then, the system builds on previous radio-frequency sleep monitoring by using three machine-learning algorithms to analyze breathing and pulse and identify the stage of sleep: light, deep, REM, or wakefulness. One algorithm uses a type of neural network common in image recognition to parse the spectrograms, or snapshots, of the data; another uses a type of neural net typically employed in tracking temporal patterns to look at the dynamics of sleep stages; a third refines the analysis to make it more generalizable across people and environments. Researchers trained the tool on about 70,000 30-second sleep intervals and tested it on about 20,000. Measured against an electroencephalogram system that was about as proficient as humans, the system identified sleep stages with 80% accuracy, versus 64% for the previous best radio frequency method, the researchers will report tomorrow at the International Conference on Machine Learning in Sydney, Australia. If the system makes it to market, doctors might soon be able to diagnose you in their sleep.