{"id":4401,"date":"2026-10-19T16:01:24","date_gmt":"2026-10-19T16:01:24","guid":{"rendered":"https:\/\/nmi.cool\/appdev\/?page_id=4401"},"modified":"2026-10-19T16:01:24","modified_gmt":"2026-10-19T16:01:24","slug":"homework-13-working-with-data-part-two-your-data-your-app","status":"publish","type":"page","link":"https:\/\/nmi.cool\/appdev\/homework-13-working-with-data-part-two-your-data-your-app\/","title":{"rendered":"Homework 13: Working with Data, Part Two \u2013 Your Data, Your App"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">In part one, you explored how information moves from a CSV file into a database and becomes available for users to view, modify, and extend.\u00a0 You also explored agentic coding, as well as how presentation and interaction can be affected by UX decisions.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now you\u2019ll apply those concepts to a dataset of your own choosing.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You\u2019ll use agentic coding to adapt the CoffeeJournal project, making decisions about how your information should be structured, stored, retrieved, presented, and manipulated.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You\u2019ll also examine how an existing application works, identify programming concepts you\u2019ve already learned, and consider how those concepts can be applied to something new.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Goals<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">We are going to expand upon the concepts explored in part one:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>The differences between source data and stored data.<\/li>\n\n\n\n<li>How data can be represented in multiple ways.<\/li>\n\n\n\n<li>How UX\/UI decisions can affect representation and interaction.<\/li>\n\n\n\n<li>The malleability of<strong> <\/strong>data \u2014 its creation, storage, editing, and deletion.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 1: Create your dataset<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Choose a subject that interests you and develop a dataset using <strong>Google Sheets, Numbers, or Excel<\/strong>:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Create approximately 8\u201310 records.<\/li>\n\n\n\n<li>Identify the properties that describe each record.<\/li>\n\n\n\n<li>Organize the information into columns, with one record per row.<\/li>\n\n\n\n<li>Consider which properties contain text, numbers, dates, or Boolean values.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Identify two questions you want your database to answer.<\/strong>  For example, a movie database might answer:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Which movies were released before 1980?<\/li>\n\n\n\n<li>Which movies have I rated four stars or higher?<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Think about how your dataset will support those questions. You may need to add or modify properties.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 2: Export your dataset<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Export your spreadsheet as a <strong>CSV (comma-separated values)<\/strong> file.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open the CSV in a text editor like Visual Studio Code. Verify that the information and column headings are preserved.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You\u2019ll use this file as the initial source data for your application.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 3: Examine and plan<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In Finder, create a copy of your original CoffeeJournal project.\u00a0 Open the <em>duplicate project<\/em> in Xcode.  Do not work with the original.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Before making significant changes, also create a safety copy of the new Xcode project \u2014 things might break!<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Start an agent conversation in <code>\/plan<\/code> mode. Ask the agent to read and follow your <code>AGENTS.md<\/code> file.  Wait for confirmation from the coding agent before proceeding.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Use the following prompt as a starting point:<br><\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<pre class=\"wp-block-code nohighlight\"><code>Please examine my current project. Analyze the following:\n\n* How it imports, stores, retrieves, and displays data.\n* The interface elements used to enable user interaction.\n\nI want to use this project as the starting point for a new application based on my own dataset.\n\nSuggest how to adapt the existing application\u2019s data handling, database structure, and interface to accommodate my information.\n\nIdentify which parts of the existing project can be reused and which need to change.\n\nDo not write any code or modify the project yet.<\/code><\/pre>\n<\/div><\/div>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Share with the agent your CSV file and the two questions you want your database to answer.<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You\u2019re also encouraged to share wireframes, sketches, photographs, color swatches, reference images, or other assets that help communicate your ideas.  You can do this simply by dragging files into the chat interface.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Discuss the agent\u2019s recommendations. Ask questions, consider alternatives, and refine the plan before approving implementation.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 4: Build the MVP<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Your first objective is to create a working <strong>MVP (minimum viable product)<\/strong>. At the very least, your application should provide the same basic functionality as CoffeeJournal, adapted to your own dataset.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Your application should:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Import your CSV into SwiftData.<\/li>\n\n\n\n<li>Display records using appropriate SwiftUI views and controls.<\/li>\n\n\n\n<li>Allow users to create, view, edit, and delete records.<\/li>\n\n\n\n<li>Preserve changes between launches.<\/li>\n\n\n\n<li>Provide ways to retrieve or present information that help answer your two guiding questions.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">You may reuse existing components and functionality from CoffeeJournal. You do not need to rebuild features that already work.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Remember what you\u2019ve already learned<\/strong><\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">In earlier exercises, you used arrays, indexes, <code>List<\/code>, and <code>ForEach<\/code> to generate lists of information. You also used <code>NavigationStack<\/code> and <code>NavigationLink<\/code> to navigate between lists and individual records.  You can review these exercises as a refresher:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/nmi.cool\/appdev\/lists-with-swiftui\/\">Lists with SwiftUI\u2060<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/nmi.cool\/appdev\/understanding-dynamic-list-foreach-and-identifiable-from-mastering-swiftui\/\">Understanding Dynamic List, ForEach, and Identifiable\u2060<\/a>.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Examine how your new application uses these same concepts with database records instead of arrays. You may recognize more of the code than you expect.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Test your application<\/strong><\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Verify that the imported information is correct and that you can create, edit, and delete records.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Quit and relaunch the application. Do your changes persist?<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Does your application help answer the two questions you identified when creating your dataset?<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Remember that changes to stored records should not modify the original CSV.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 5: Evaluate and improve<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Once your application is working, return to <code>\/plan<\/code> mode.  Ask the agent the following:<br><\/p>\n\n\n\n<pre class=\"wp-block-code nohighlight\"><code>Keeping in mind the guidelines in my AGENTS.md file, please review my application and suggest efficiencies and possible improvements.\n\nConsider whether the number of SwiftUI View files could be reduced or whether related views could be combined. Also consider opportunities to simplify navigation, including the use of NavigationStack for displaying individual records.\n\nExplain your recommendations and identify which changes would be relatively simple to implement. Do not modify the project yet.\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Evaluate the agent&#8217;s suggestions:<br><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Which improvements would make the application more useful?<\/li>\n\n\n\n<li>Could related views be combined without making the code harder to understand?<\/li>\n\n\n\n<li>Are there simpler or more appropriate interface controls?<\/li>\n\n\n\n<li>Could information be organized or presented more effectively?<\/li>\n\n\n\n<li>Would any suggested changes introduce unnecessary complexity?<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Choose improvements worth implementing. <strong>You do not have to accept every recommendation.<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Make meaningful visual and functional improvements. Use SF Symbols and appropriate SwiftUI controls, but focus on clarity and usability rather than decoration.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You may continue refining the visual design outside class.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The agent can implement your decisions, but <strong>you are responsible for deciding what information matters, how it is presented, and how users interact with it.<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Consider when making a change yourself might be quicker \u2014 <em>and use less of your account tokens<\/em> \u2014 than asking the agent.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step 6: Reflect<\/strong><\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Be prepared to demonstrate your application and explain:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>How your dataset influenced the application\u2019s structure and interface.<\/li>\n\n\n\n<li>How the application helps answer your two guiding questions.<\/li>\n\n\n\n<li>What you reused or changed from CoffeeJournal.<\/li>\n\n\n\n<li>Which agent recommendations you accepted or rejected, and why.<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>In part one, you explored how information moves from a CSV file into a database and becomes available for users to view, modify, and extend.\u00a0 You also explored agentic coding, as well as how presentation and interaction can be affected by UX decisions. Now you\u2019ll apply those concepts to a dataset of your own choosing. &hellip; <a href=\"https:\/\/nmi.cool\/appdev\/homework-13-working-with-data-part-two-your-data-your-app\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Homework 13: Working with Data, Part Two \u2013 Your Data, Your App<\/span><\/a><\/p>\n","protected":false},"author":20,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-4401","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/pages\/4401","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/users\/20"}],"replies":[{"embeddable":true,"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/comments?post=4401"}],"version-history":[{"count":12,"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/pages\/4401\/revisions"}],"predecessor-version":[{"id":4414,"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/pages\/4401\/revisions\/4414"}],"wp:attachment":[{"href":"https:\/\/nmi.cool\/appdev\/wp-json\/wp\/v2\/media?parent=4401"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}