Learn how to select the best feature for training a machine learning model to predict taxi fares. Understand key concepts for the AI-900 Microsoft Azure AI Fundamentals certification exam.
Table of Contents
Question
You have received a dataset that contains information about taxi journeys that occurred during a given period. You need to train a model to predict the fare of a taxi journey. What should you use as a feature?
A. the number of taxi journeys in the dataset.
B. the trip distance of an individual taxi journey.
C. the fare of individual taxi journeys.
D. the trip ID of individual taxi journeys.
Answer
When training a machine learning model to predict taxi fares, you should use the trip distance of individual taxi journeys as a feature (choice B).
B. the trip distance of an individual taxi journey.
Explanation
The goal is to predict the fare amount, which is the target variable or label you want the model to learn to predict. To do this, the model needs relevant input features that have a relationship with the target variable.
Trip distance is directly related to the fare amount – longer trips will typically have higher fares than shorter trips. So the distance of each individual journey is highly relevant information that the model can learn from to predict fares.
In contrast:
- The total number of journeys in the dataset (A) is not relevant for predicting individual fares.
- The actual fare amounts (C) cannot be used as input features, since those are what you are trying to predict.
- The trip IDs (D) are just arbitrary identifiers with no meaningful relationship to the fare amounts.
So in summary, to predict taxi fares, you should use information about each individual trip that relates to its fare, with trip distance being the best choice of the options provided. The model can learn the relationship between distance and fare to make accurate fare predictions.
In predicting the face of a taxi journey, the trip distance is a crucial feature because there is usually a strong relationship between the distance traveled and the fare charged. Other features like the number of journeys or trip ID are irrelevant for predicting the fare, and using the fare itself would defeat the purpose of making a prediction.
Microsoft Azure AI Fundamentals AI-900 certification exam practice question and answer (Q&A) dump with detail explanation and reference available free, helpful to pass the Microsoft Azure AI Fundamentals AI-900 exam and earn Microsoft Azure AI Fundamentals AI-900 certification.