LifeTracker User Guide

LifeTracker User Guide

Introduction

LifeTracker is an application that allows users who are health conscious automate the tracking of their calories and keep a record of their calorie intake history.

The app also allows users to keep track of their daily exercises to compute their calorie loss.

Their net calorie gain/loss can then be viewed.

Quick Start

  1. Ensure that you have Java 11 or above installed.
  2. Down the latest version of LifeTracker from here.
  3. Copy the file to the folder you want ot use as the home folder for your LifeTracker.
  4. Open a command terminal, cd into the folder you put the jar file in, and use the java -jar lifetracker.jar command to run the application.
  5. Type the command in the command box and press Enter to execute it.
  6. Refer to the features below for details of each command.

Features

  • View and Update user profile
  • Add meal
  • Delete meal
  • Add Exercise
  • Calculate caloric needs
  • Calculate amount of calories left in the day
  • Find the nutrition of a certain kind of food
  • Filter foods based on calories
  • Track Calorie Intake

Viewing User Profile: view

To view user’s profile. User can simply input a single line command to view the specific information in their user profile using the format below.

Format: view /[fieldName]

Here is a table of the information that the user can choose to view alongside the field name of it:

Information

/[fieldName]

Name

/name

Weight

/weight

Height

/height

Age

/age

Gender

/gender

Daily caloric limit

/caloricLimit

Calories remaining for today

/caloriesLeft

Target weight

/targetWeight


Example:

view-example

Updating User Profile: update

Allows the user to update any of their information. User can simply input a single line command to update the specific information in their user profile using the format below.

Format: update /[fieldName] [newInfo]

Here is a table of the information that the user can choose to update alongside the field name of it:

Information

/[fieldName]

Comments

Name

/name

For more than one name, separate with an underscore. E.g Firstname_LastName

Weight

/weight

Weight can only take in numbers between 0 and 700 kg.

Height

/height

Height can only take in numbers between 0 and 300 cm.

Age

/age

Age can only take in numbers between 0 and 120 years old.

Gender

/gender

Gender can only take in male or female as arguments.

Target weight

/targetWeight

TargetWeight can only take in numbers between 0 and 700 kg.


Example:

update-example

Adding a meal: add

Adds a new meal to database

Format: add /on [date] /type [MealType] /foods [foods]

  • The date should be in d/M/yyyy format
  • The MealType can be one of the following
    • Breakfast
    • Lunch
    • Dinner
  • The foods is a list of foods seperated by , (Comma with a space after)

Example of usage:

add /on 3/3/2023 /type Lunch /foods Spaghetti, Alfredo (Small)

add-example

Alternatives

For users who are not experienced with typing fast on keyboards, LifeTracker offers a menu option to add meal

Format: add

add-alt-example

Listing foods: list

For users to view all foods currently supported in the LifeTracker database

Format: list foods

Example: list-foods-example

Listing meals: list

For users to view previously added meals

Format: list meals

Example: list-meals-example

Listing exercises: list

For users to view previously added exercises

Format list exercises

Example: list-exercises-example

Deleting meals and exercises: delete

For users to remove previously added meals and exercises

Format: delete /[meal, exercise] [index]

  • The index should be a positive integer and must be less than number of meals/exercises added
  • It is recommended to run list meals/exercises beforehand to get the index of the meal/exercise you want to delete

Example: delete-example

Filtering foods: filter

For users to filter the foods by their calorie content. The user inputs the lower and higher bound that they want to filter the food by, in terms of the calorie content of the food.

The list of food within the range will then be displayed, from which the user can choose from.

Format: filter [lower_bound] [upper_bound]

  • The lower and upper bound should be a float value
  • The lower bound should be lower than or equal to the upper bound

Example: filter-example

View nutrition content of food: nutrition

For users to view the nutrition content of the food. The user first needs to search for the food, then the nutrition content of the food will be printed.

Format: nutrition

  • The first food search should be in English
  • To select the particular food filtered, an integer should be inputted

Example: nutrition-example

Adding an exercise: exercise

For user to input the exercise done previously.

Format: exercise /type [exercise_name] /description [exercise_description] /calories [calories_burnt] /on [date]

  • The exercise name and exercise description accepts any input
  • The calories should be in float format
  • The date should be in d/M/yyyy format

Example: exercise-example

Tracking net calorie intake: track

For user to track their previous net calorie intake.

There are 2 options to run this command:

1) For user to view all their calorie history from past meals and exercises input Format: track all

2) For user to view calorie history within a specified time-frame Format: track /start [start_date] /end [end_date]

  • The dates should be in d/M/yyyy format

Output: track-example

Displaying examples of meals and exercises: examples

For user to gain some inspiration on exercises to do, as well as some idea on the meals that they can eat.

Format: examples [meal/exercise]

Example: examples-example

Exiting the application: bye

Allows user to exit the appliction.

Format: bye

Output: bye-example

FAQ

Q: How do I transfer my data to another computer?

A: Do copy the data folder and its contents to the new computer

Q: Where do you get the data for the food from?

A: The nutrition data is based on food from NUS TechnoEdge canteen, as this application would be mainly targeted at NUS Engineering students who eats there regularly.

Command Summary

Note: 1) Fields within square brackets are variable and are to be changed according to user needs. 2) Fields with a comma inside the square brackets indicate that any of the multiple options can be input according to user needs.

Action

Format, Examples

View

view /[fieldName]

Update

update /[fieldName]

Add

add /on [date] /type [MealType] /foods [foods] OR add

List

list [foods, meals, exercises]

Delete

delete /[meal, exercise] [index]

Filter

filter [lower_bound] [upper_bound]

Nutrition

nutrition

Exercise

exercise /type [exercise_name] /description [exercise_description] /calories [calories_burnt] /on [date]

Track

track all OR track /start [start_date] /end [end_date]

Examples

examples [meal, exercise]

Help

help

Exit

bye