If you read the python console start message you will notice that some modules and some variables are builtin or have been imported for our convenience. eg bpy and C = bpy.context.
PYTHON INTERACTIVE CONSOLE 3.7.3 (default, Apr 3 2019, 19:16:38) [GCC 8.0.1 20180414 (experimental) [trunk revision 259383]]
Command History: Up/Down Arrow
Well, I still can't find a way to change an object, but I did find out how to delete the current object and create a slightly altered object for every frame.
The key is to use bpy.app.handlers:
import bpy, math
#remove all default objects
bpy.data.objects['Cube'].select = True
bpy.data.objects['Camera'].select = True
bpy.data.objects['Lamp'].select = ...
Thankyou @RobertGützkow for your help!
The solution was true that I needed to have a python-specific file (outside of blender) that I could run.
To do this I
1) created a new Text.txt file
2) named it the same name as my script (optional)
3) copied and pasted the code into the text.txt file
4) rename the text.txt --> text.py
5) add the text.py file path ...
You need to run the Blender executable from the command line.
In Windows this requires you to run a new Command Prompt and the execute blender.exe from the correct location.
In Linux/MAC the process is similar.
On my Windows machine, I go to the Start Bar and type in Command
in the new window I type the directory to where Blender was installed followed ...