When the time comes to choose a major, many college students are torn between going with a subject they're most interested in and choosing a field that will set them up for a plum job after graduation. The good news is that it's often possible to do both.

In fact, 4 in 5 undergraduates choose a major that is connected to strong job prospects, according to a 2015 report by the Georgetown University Center on Education and the Workforce. Here are eight hot areas you may want to consider.

Mechatronics engineering. Standing at the juncture between mechanical and electrical engineering, mechatronics is an interdisciplinary field that teaches students how to build and control mechanical devices like motors and robots and how to take sensor data and turn it into commands.

"Mechatronics is a huge growth area for modern technology, especially robotics and autonomous driving," says Jonathan Rogers, an associate professor in the department at Georgia Institute of Technology in Atlanta who specializes in automation and mechatronics.

Purdue University in Indiana and Middle Tennessee State University are among what is for now a small handful of institutions offering a dedicated mechatronics major; most undergrads specializing in the field do so under the umbrella of mechanical engineering. They typically take courses in 3D modeling, dynamics and control systems.

In general, engineering grads have the highest average starting salary – roughly $66,500 – according to a 2018 survey by the National Association of Colleges and Employers. Other engineering fields with strong earnings potential include petroleum engineering, mining and mineral engineering, and chemical engineering, according to the Georgetown report.

Business. Besides taking courses in accounting, finance, marketing, business law and management, business majors often work on team projects involving real-world case studies and participate in internships or hands-on experiences, including working with industry partners. It's one of the most popular areas – and for good reason.

At the bachelor's level, eight of the 10 top majors in demand by employers are in the business category, such as accounting or sales, according to NACE.

"We've seen a growth in new business practices, which involves managing more complicated work spaces and processes and juggling telecommuters and interconnectivity with global economies," says Jeff Strohl, director of research at the Georgetown Center on Education and the Workforce.

International business and finance majors have the highest combination of midcareer median pay, at $112,200, and annual job growth, at 10 percent, according to PayScale, a compensation software and data company.

The reason: "More companies are going global, especially as it's easier to do so through technology," says Lydia Frank, vice president of content strategy at PayScale. "It's important to have someone who can navigate the standard business practices and customs in different locations."

Computer science. Gone are the days when the field was practically synonymous with computer programming. Now, computer scientists have their hands in everything from creating cutting-edge educational tools and driverless vehicles to doing sophisticated data mining in health care to making advances in cybersecurity, robotics and artificial intelligence.

With digital technology influencing just about everything in the world and "new products being developed that are digitally driven, the future is really about creativity with computer science," says Edwin Koc, director of research, public policy and legislative affairs at NACE.

For the class of 2018, CS degrees are expected to command a starting salary of about $66,000, according to NACE, the second-highest figure after engineering. And jobs in computing and information technology are expected to grow nearly twice as fast as the average for all careers, adding more than half a million new jobs from 2016 to 2026, according to the Bureau of Labor Statistics.

The discipline's reach is widespread; its influence is felt in fields from the arts and politics to medicine. "For example, in health care, research at Carnegie Mellon is changing how kidney donors and patients are matched and, in public policy, our researchers are exploring techniques to address the difficult problem of eliminating gerrymandering in the drawing of political boundaries," says Srinivasan Seshan, professor of computer science and the head of the department at Carnegie Mellon University in Pittsburgh.

Data science. "Data runs the world now," Koc says. Indeed, by 2020, the number of positions for data and analytics experts in the U.S. is expected to increase by 364,000 to a total of more than 2.7 million, according to a 2017 report from Burning Glass Technologies, a labor market analytics company.

Those steeped in the subject are at the forefront of predictive analytics – helping companies like Google and Yahoo improve their search engine functionality, or giving doctors and clinicians the tools to more effectively customize medical treatment to individual patients based on specific data points. Data scientists also play an important role in risk assessment within the credit card industry and in allocation and optimization of resources in environmental science and public policy.

"We're in an era where data is readily available, easy to collect, and people appreciate the value of making decisions based on empirical data," says Daniel Gillen, professor and chair of the department of statistics at the University of California—Irvine, which launched a new bachelor's in data science degree in 2015.

Other colleges with data science/analytics programs for undergrads include the University of Rochester in New York, Denison University in Ohio and Pennsylvania State University.

Cognitive science. This relatively new interdisciplinary field blends elements of psychology, computer science, philosophy, neuroscience and linguistics. In other words, it studies the mind, its processes and the nature of intelligence.

"It's really about how people think in mental terms and neural terms," says Michael McCloskey, professor of cognitive science at Johns Hopkins University in Baltimore, where the number of students choosing the major has doubled in the last five years.

There's an emphasis on how to think critically and engage in constructive problem-solving. Cognitive science majors go on to work in health care settings, such as in hospital administration or as research coordinators in labs; neuropsychological testing centers; business-related careers such as marketing; and the technology sector, among others. The major can also be good training for medical school, law school and business school, McCloskey notes.

Nursing. The nursing field is projected to add more than 64,000 jobs between 2016 and 2026, according to the BLS, a 31 percent increase.

"Health care is one of the fastest-growing sectors of the economy, and our research has shown it has a large skills gap, with 1.7 openings per worker for advanced clinical care roles like nurse practitioners," notes Matt Sigelman, CEO of Burning Glass Technologies.

"Studies have shown that nursing is one of the few occupations not decreasing due to technological innovation," says Patricia M. Davidson, dean and professor at the Johns Hopkins School of Nursing.

As part of their undergraduate education, nursing majors take classes in pharmacology, biostatistics, pathophysiology, chronic health assessment and health promotion. Students also participate in clinical rotations working with real patients alongside physicians and other health professionals, as well as "simulation labs, which offer a safe environment for students to practice hands-on skills and procedures," Davidson says.

Pharmaceutical sciences. Pharmaceutical sciences "is an area where the human touch is going to remain strong," Strohl says. "People like to talk to their pharmacists."

Undergrad programs aim to prepare students for technical positions in the development, production or sales divisions of drug companies or for a career as a pharmacist or pharmaceutical researcher. With a B.S. in pharmaceutical sciences, you can work as a pharmacy assistant or technician or in sales for drug companies.

With a median annual salary of $113,000, those who major in pharmacy, pharmaceutical sciences or pharmaceutical administration have the only nonengineering major among the top 10 ranked by wages, according to Georgetown's research.

After gaining a foundation with courses in math and science, pharmacy majors progress to advanced coursework in drug design, mechanisms of drug action, toxicology, quality assurance, regulatory compliance and other issues.

For instance, at the University of Michigan's College of Pharmacy, which offers a bachelor's in pharm sciences, majors study the chemistry of medicines and drug delivery systems, regulatory issues and ethical concerns related to drug discovery.

Human resources. Even in an increasingly automated world, there's no taking the "human" out of human resources – these are the professionals who handle hiring, training and other employee relations tasks for companies or organizations. "Going into the future, human resources looks to have more demand than supply," Koc says. The field is another one that is transforming because of data.

"Two important trends in HR are the increasing use of people analytics to drive HR decisions and the expansion of the scope of employee assistance programs offered by employers," says Peter Madsen, associate professor of organizational behavior and human resources in the Brigham Young University Marriott School of Business in Utah. Among the school's 2017 class of 40 HR management majors, 97 percent of those seeking jobs had positions within three months of graduating.

Usually under the umbrella of a business program, an HR major typically includes coursework in organizational behavior, applied social psychology, talent management, labor relations and employment law, plus business fundamentals.

"The power of this major is its utility across industries, sectors and locations," says Erin Bass, an associate professor of management at the University of Nebraska—Omaha. "Any organization that employs people needs HR majors to help recruit, retain and engage its employees."