Milliman Data Science Interview Questions and Answers


Securing a position in the competitive field of data science and analytics at Milliman requires more than just technical prowess—it demands a deep understanding of the industry, a sharp analytical mind, and the ability to communicate effectively. To help you prepare for your interview, let’s dive into some common questions and their answers that might be asked during the hiring process.

Table of Contents

R Shiny Interview Questions

Question: What is R Shiny?

Answer: R Shiny is an open-source web application framework for R that allows users to create interactive web applications directly from R scripts. It enables data scientists and analysts to build web-based dashboards, visualizations, and interactive tools without needing to know HTML, CSS, or JavaScript.

Question: How does a Shiny application work?

Answer: A Shiny application consists of two main components: a user interface (UI) definition and a server function. The UI definition specifies the layout and appearance of the application, while the server function contains the logic and calculations. When a user interacts with the UI, inputs are sent to the server, where they trigger reactive expressions or functions that update the UI dynamically.

Question: What are reactive expressions in Shiny?

Answer: Reactive expressions are functions in Shiny that automatically update their outputs whenever their inputs change. They are used to create dynamic and responsive behavior in Shiny applications by allowing certain parts of the UI to be updated in real time based on user input or changes in data.

Question: Explain the difference between renderUI and uiOutput in Shiny.


  • renderUI is a server-side function in Shiny that generates dynamic UI elements based on reactive inputs or conditions. It is used to create UI elements dynamically within the server function.
  • uiOutput is a UI-side function that defines a placeholder for dynamic UI elements generated by renderUI. It is used within the UI definition to specify where the dynamically generated UI elements should be inserted.

Question: How do you handle user authentication and authorization in a Shiny application?

Answer: User authentication and authorization can be implemented in Shiny applications using various methods, such as:

  • Integration with authentication systems like OAuth or LDAP.
  • Implementing custom authentication logic using Shiny’s session management functions and user input validation.
  • Restricting access to certain parts of the application based on user roles or permissions using conditional rendering and reactive expressions.

Question: How do you deploy a Shiny application for production use?

Answer: Shiny applications can be deployed for production use using various methods, such as:

  • Hosting on Shiny Server or Shiny Server Pro, which are dedicated servers for deploying and managing Shiny applications.
  • Deploying on cloud platforms like AWS, Google Cloud Platform, or Microsoft Azure using containerization technologies like Docker.
  • Using, a cloud-based platform provided by RStudio, for easy deployment and hosting of Shiny applications.

SAS Interview Questions

Question: What is SAS?

Answer: SAS (Statistical Analysis System) is a software suite developed by SAS Institute for advanced analytics, business intelligence, and data management. It provides a wide range of tools and capabilities for data manipulation, statistical analysis, predictive modeling, and reporting.

Question: Explain the difference between SAS functions and SAS procedures.


  • SAS functions are predefined operations that perform specific tasks on data, such as mathematical calculations, string manipulation, and date/time operations. They are used within data steps or procedures to transform or manipulate data.
  • SAS procedures (PROCs) are prewritten programs that perform specific analytical or data processing tasks, such as summarizing data, performing statistical analysis, or generating reports. They are invoked using the PROC statement and produce output in the form of tables, listings, or graphics.

Question: What are some commonly used SAS functions for data manipulation?

Answer: Commonly used SAS functions for data manipulation include:

  • SUBSTR(): Extracts substrings from character variables.
  • UPCASE() and LOWCASE(): Convert character strings to uppercase or lowercase.
  • TRIM(): Removes leading and trailing blanks from character strings.
  • DATEPART() and TIMEPART(): Extract date and time components from datetime values.
  • INTNX(): Computes dates by adding or subtracting intervals from a given date.

Question: What are the different types of joins supported by SAS?

Answer: SAS supports four types of joins:

  • Inner Join: Combines matching rows from two or more datasets based on a common key variable.
  • Left Join: Retains all rows from the left dataset and includes matching rows from the right dataset.
  • Right Join: Retains all rows from the right dataset and includes matching rows from the left dataset.
  • Full Outer Join: Retains all rows from both datasets and includes matching rows from each dataset.

Question: Explain the concept of format and information in SAS.

Answer: In SAS, formats and information are used to control the appearance and interpretation of data values, respectively. A format is used to display data values in a specific format, such as date formats, currency formats, or custom formats. An information is used to read data values from external sources and convert them into SAS internal representation.

Question: What is PROC SQL in SAS, and how is it different from traditional SAS procedures?

Answer: PROC SQL is a SAS procedure that provides SQL (Structured Query Language) functionality for data manipulation and querying. It allows users to perform tasks such as selecting, joining, filtering, and summarizing data using SQL syntax. Unlike traditional SAS procedures, PROC SQL offers more flexibility and expressive power for data manipulation, especially when dealing with complex queries or external databases.

Python Interview Questions

Question: What are decorators in Python?

Answer: Decorators are a powerful feature in Python that allows you to dynamically modify the behavior of functions or methods. They are implemented using the @ symbol followed by the decorator function name, which is applied to the target function. Decorators are commonly used for adding logging, authentication, or caching to functions.

Question: Explain the difference between == and is in Python.


  • The == operator checks for equality of values, i.e., whether the values of two objects are the same.
  • The is operator checks for identity, i.e., whether two objects refer to the same memory location in Python.

Question: What is a virtual environment in Python, and why is it used?

Answer: A virtual environment is a self-contained directory that contains a Python interpreter and a set of libraries installed for a specific project. It helps in isolating project dependencies and avoids conflicts between different projects. Virtual environments are used to manage project-specific packages, dependencies, and configurations.

Question: What is the purpose of the __init__ method in Python classes?

Answer: The __init__ method is a special method in Python classes that is called automatically when a new instance of the class is created. It is used to initialize the object’s attributes or perform any setup tasks required for the object.

Question: What is list comprehension in Python, and how is it used?

Answer: List comprehension is a concise way to create lists in Python by applying an expression to each item in an iterable. It follows the syntax [expression for an item in iterable if condition], where the condition is optional. List comprehension is often used to replace loops for creating lists more efficiently and elegantly.

Question: How do you handle exceptions in Python?

Answer: Exceptions in Python are handled using the try, except, and finally blocks. The try block is used to wrap the code that might raise an exception, while the except block is used to handle specific exceptions or error conditions. The finally block is optional and is used to execute cleanup code regardless of whether an exception occurred.

R packages Interview Questions

Question: What is an R package, and why are they used?

Answer: An R package is a collection of R functions, data, and documentation bundled together for a specific purpose or task. They are used to extend the functionality of R by providing pre-written code for various tasks such as data manipulation, statistical analysis, visualization, and machine learning. Packages help in organizing and sharing code, promoting code reuse, and enhancing productivity.

Question: How do you install and load an R package?

Answer: R packages can be installed from CRAN (Comprehensive R Archive Network) using the install.packages() function. For example:



Once installed, you can load a package into the current R session using the library() function. For example:



Question: What are some commonly used R packages for data manipulation and visualization?

Answer: Some commonly used R packages for data manipulation and visualization include:

  • dplyr: For data manipulation tasks like filtering, summarizing, and joining datasets.
  • ggplot2: For creating elegant and customizable graphics based on the Grammar of Graphics principles.
  • tidyr: For tidying and reshaping messy datasets into a tidy format.
  • table: For fast and efficient manipulation of large datasets using data.table syntax.

Question: Explain the purpose of the devtools package in R.

Answer: The devtools package in R is a collection of tools for developing and managing other R packages. It provides functions for installing packages from GitHub repositories, checking package dependencies, building and installing packages locally, and documenting packages. devtools simplifies the package development process and streamlines tasks such as version control and collaboration.

Question: What is the purpose of the roxygen2 package in R?

Answer: The roxygen2 package in R is used for generating documentation for R packages in a format compatible with the Roxygen documentation system. It allows users to write documentation directly in the source code using special Roxygen comments and then automatically generate documentation files such as.Rd files and NAMESPACE files during the package build process. This streamlines the documentation process and ensures consistency between code and documentation.


Preparing for a data science and analytics interview at Milliman requires a combination of technical expertise, domain knowledge, and problem-solving skills. By familiarizing yourself with these common questions and practicing your responses, you’ll be better equipped to showcase your abilities and secure your dream job in this exciting field. Good luck!


Please enter your comment!
Please enter your name here