If you’re uncertain what to do about your risk for heart problems, ask the wizard at HealthPartners.

The Bloomington-based health care provider has received a $3 million federal grant through its research institute to expand access to a computer program called CV Wizard, which analyzes patients’ medical records for cardiac clues that would be helpful to doctors and patients.

Doctors like the way the system works behind the scenes to generate advice before a patient’s visit, said Dr. JoAnn Sperl-Hillen, a co-creator of the program and co-director of HealthPartners’ Center for Chronic Care Innovation. A similar HealthPartners’ tool for diabetes appears to have reduced blood sugar scores for patients who used it, compared to a control group.

“This technology makes the electronic health record more helpful rather than just being used as a documentation and billing tool,’’ Sperl-Hillen said. “It makes it easy for providers to do the right thing.”

The wizard is already in use at HealthPartners and Park Nicollet clinics in the metro area, along with Essentia clinics in northern Minnesota. The new grant will make it available to 60 safety net clinics around the United States, which Sperl-Hillen said will test its ability to improve outcomes because patients at such clinics are often sicker and less able to stick to guidance and medications.

You might not need a computer algorithm to tell patients that smoking is bad and exercising is good, but heart risks are also based on genetics, age, gender, race, cholesterol, blood sugar and other traits. The wizard factors in all of that and differentiates between one bad blood pressure reading for a patient and several in a row.

To keep it current and accurate, researchers and clinic groups using the wizard frequently review the clinical guidelines on which the system bases its advice. For example, it currently uses an American Heart Association calculator for determining whether patients should take statins to lower their cholesterol, but researchers are evaluating new and more conservative guidance from the U.S. Preventive Services Task Force.

The goal is to give patients and doctors the best guidance to make their own decisions, Sperl-Hillen said. “We really try not to be dictatorial.”