M: Do you know Pokémon go?
G: Yes, I’m familiar with Pokémon GO. It’s an augmented reality mobile game where players explore the real world to catch Pokémon, battle in gyms, complete raids, and participate in various events. Are you looking for tips, event updates, or something else?
M: I’m trying to build some kind of system in which, given a list of the Pokémon moves and the statistics related to them, I can contrast and compare the statistics of multiple move combinations, selectively. I can do it slowly in a manual method with what I know of spreadsheets using libre office Calc, and I know enough programming that if it were a larger project, I could simply write a Python program. Answer briefly. Can I do this in a spreadsheet, or do I need to shift to a database? And either way, can you please give me a broad strokes breakdown of what I need to do to accomplish this task?
G: You can accomplish this in a spreadsheet if the dataset is relatively small and manageable. A database is better if you expect the data to grow significantly or require complex querying.
SUM,
AVERAGE, IF, and VLOOKUP to
compare and analyze stats.SELECT SUM(damage) FROM moves WHERE...).A spreadsheet is sufficient for small-scale analysis, but a database is better for scalability and advanced querying.
M: Let’s say from two tables - “Fast” and “Charge” - of about 100 elements, I want to pull 3-6 entries from each, then perform calculations on each combination of Fast and Charge and display the results. There will be minimal change in the data after the initial creation. Please summarize the pros and cons of each approach, spreadsheet and database.
G:
Pros:
Cons:
Pros:
Cons:
For your scenario, spreadsheets are simpler and sufficient, but if you anticipate scaling up or require frequent, complex analysis, consider a database.
M: Let’s go with spreadsheet. Assume I have the data entered: two simple tables on separate sheets in Libre office. How do I go from this data to the previously stated goal being able to select multiple entries from each, perform calculations, and return a readable table showing the resultant calculations of each combination? I apologize for the vagueness, but: please attempt to be as detailed as possible, without being overly verbose.
G: Here’s a clear, step-by-step process for achieving your goal in LibreOffice Calc:
Name, Damage, Energy,
etc.Name, Damage,
Energy Cost, etc.In a new sheet ("Selections"):
Tip: Use Data → Validity for dropdowns or a manual list.
FILTER or conditional logic (IF and
INDEX):
=IF(A1=1, Sheet1.A2, "") (if using
checkboxes).VLOOKUP to
pull corresponding data.Fast
move with each Charge move:
Fast moves (repeated for each
Charge).Charge move paired with every
Fast move.Fast and 4 Charge,
you'll create 12 rows.Total Damage = Fast.Damage + Charge.DamageEfficiency = (Fast.Damage / Energy) + (Charge.Damage / Energy Cost)VLOOKUP or INDEX/MATCH to reference
the stats dynamically.Fast Move, Charge Move,
Total Damage, Efficiency, etc.This approach leverages basic spreadsheet functions while keeping it maintainable. For a more dynamic experience, you could consider using macros, but they aren't strictly necessary for your stated goal.
M: If necessary, please modify (if necessary, I haven’t looked into it yet) number four to account for the fact that the exact number of necessary fast and charge moves for each analysis is variable from test to test. The point is to automate as much as possible; having to rebuild the helper tables for each quantity is the kind of automation needed.
G: To handle variable numbers of selected moves and automate the creation of the helper table in step 4, here’s an improved approach:
Use named ranges or dynamic arrays:
FILTER or conditional logic (e.g., only pull
rows where the selection is valid).Fast
moves in column A and Charge moves in column B.Dynamic Row Count:
COUNTA or similar.=COUNTA(A:A) for the count of
Fast moves.To automate combinations:
Fast move for the count of
Charge moves.Charge moves repeatedly to
align with the Fast repeats.Assume:
SelectedFast is in "Selections" A1:A (dynamic
range).SelectedCharge is in "Selections" B1:B (dynamic
range).First Column (Fast Moves):
=INDEX(Selections.A$1:A$100, INT((ROW()-1)/COUNTA(Selections.B$1:B$100))+1)Fast move enough times to match all
Charge moves.Second Column (Charge Moves):
=INDEX(Selections.B$1:B$100, MOD(ROW()-1, COUNTA(Selections.B$1:B$100))+1)Charge moves.With this setup, the helper table grows and shrinks based on the number of selected moves, ensuring full automation of the pairing process. All downstream calculations and results will update dynamically.