Staying sexually active—and considering sexuality an important part of life—may be linked to higher cognitive functioning as people age, according to a study in the March issue of the American Journal of Geriatric Psychiatry.

Older men and women who were satisfied with their sexual relationships and considered sexuality an essential component of aging performed better on tests of cognitive function than those who felt sexuality and intimacy were unimportant, the research showed.

Previous studies have focused on the prevalence of sexual activity in older people. But the influence of cognitive decline on how sexuality is perceived in later life wasn’t known, researchers said.

The study, conducted in the Netherlands, involved 1,747 men and women from a larger study of aging. The subjects were 71 years old, on average. About three-quarters had partners. Researchers assessed cognitive function with tests of memory, mental processing speed, general cognitive function and fluid intelligence, or the ability to reason and think abstractly.

Subjects responded to four questions about the importance of sexuality personally and to older people generally, and about their current sex life and need for intimacy and touching with aging. Chronic diseases, depression and medications were recorded.

A quarter of the subjects rated their current or personal sexuality as important or very important, while 41 percent rated it as unimportant. Nearly 28 percent agreed that sexuality at an older age isn’t important anymore; 42 percent felt it was important.

Current sexual activity was considered pleasant and unpleasant by 32 percent and 6 percent, respectively, but 67 percent believed intimacy and touching are still needed in older people, while 12 percent didn’t agree.

Click for more from The Wall Street Journal.