| Gregory's profileStop Making SensePhotosBlogNetwork | Help |
|
Stop Making SenseUse your brain, nobody else will! July 01 The Need to RefactorThere are times when you look at code and you know it has to be retooled. Yesterday was one of those times. I want you to look at a bit of code. The following routine was written by a group of programmers from offshore. One theory amongst my peers is this code was purposefully written this way to get more billable hours. Another theory is the developers just don’t know any better. I am not here to worry about the reasons the code is the way it is, but rather to take you through an exercise in maintaining difficult code. First, here is the original code: private void WriteDiscoverFile() writer.WriteLine(this.GetFileHeaderRec().ToUpper()); try while (enumerator.MoveNext()) IEnumerator enumerator2 = null; try while (enumerator2.MoveNext()) finally writer.WriteLine(current.GetBatchTrailerRec().ToUpper()); writer.WriteLine(this.Group.GetGroupTrailerRec().ToUpper()); When you first see this code, you probably wonder what is going on? How can I maintain this? But a closer look at the code gives some hints to what is happening. Let’s break it down, in English. Here are the steps:
Let’s go step by step. First, the signature leaves us where we cannot easily unit test the code. There is too much magic being pulled from the object at hand, so we change this to get rid of the magic. The result is the following signature: private void WriteDiscoverFile(string fullFileName, bool append, Encoding encoding, Group group) { } Although I am only passing the information from within the class, this allows me to mock the Group object so I can test the code in a predictable manner rather than running the production file and then examining for mistakes. The next few lines are nearly equivalent, although I have removed the My object, as it was a bit of overkill. In addition, the original code was magically pulling the value from the My object. This was not a huge problem, as the code was all contained in the UI project, but I am now separating out tiers, so pulling from My, which is essentially a .config wrapper in this case, broke encapsulation. That is bad, largely unmaintainable (or at least difficult to maintain) and fairly messy to work with. I won’t go further on this aside. Here are the next few lines: SortedList<string, Batch> batches = group.Batches; I did pull the SortedList for batches, which was magically pulled from the object earlier. There was nothing wrong with the initial implementation, except it required spinning up the object and exposing a Set method on batches (which should be read only, as they are pulled from the database and calculated). By inverting the code a bit and allowing the method that calls WriteDiscoverFile() to send in the group, I can isolate the WriteDiscoverFile() method and test it. The writer lines, as mentioned are pretty much the same as before. The enumerators are just a way to loop. Another fine loop (and cleaner in this case) is the for loop. Here is the bulk of the routine: foreach (Batch batch in batches.Values) foreach (Transaction transaction in transactions.Values) writer.WriteLine(batch.GetBatchTrailerRecord()); This is much cleaner and the intent is very clear, making this much easier to maintain. I then finish off writing out the trailers and get rid of the Writer, as follows: writer.WriteLine(group.GetGroupTrailerRecord()); Here is the entire routine: private void WriteDiscoverFile(string fullFileName, bool append, Encoding encoding, Group group) { SortedList<string, Batch> batches = group.Batches; StreamWriter writer = new StreamWriter(fullFileName, append, encoding); writer.WriteLine(GetFileHeaderRecord()); writer.WriteLine(group.GetGroupHeaderRecord()); foreach (Batch batch in batches.Values) { string batchHeader = batch.GetBatchHeaderRecord(); SortedList<string, Transaction> transactions = batch.Transactions; writer.WriteLine(batch.GetBatchHeaderRecord()); foreach (Transaction transaction in transactions.Values) { writer.WriteLine(transaction.ToString()); } writer.WriteLine(batch.GetBatchTrailerRecord()); } writer.WriteLine(group.GetGroupTrailerRecord()); writer.WriteLine(GetFileTrailerRecord()); writer.Close(); } Which would you rather maintain? SummaryWhat have we done here? Here is a list
In the end, we have 14 lines of code (getting rid of the braces) versus 30 (many of which would never be hit or were always true). There is one question that might come to mind. Why did I remove the error handling bits? The main reason is I did not see them as necessary, as the process has run in the same location for ages. But, if I were to feel it was needed, rather than have a bunch of nested tries, I would simply surround the instantiation of the StreamWriter, as that is the only point I can see failure occurring. It would look like this: try Note that we can also use a using statement if we do not wish to log, and allow the failure to create file error to bubble up to the UI. It really depends on whether or not we have a true user interface or not. My vote is not, as this should be an automated process, but that is a topic for another day. Peace and Grace, Twitter: @gbworld June 26 IT Adding Value to BusinessI have been working on a nightmare (yes, it is reporting – isn’t that always a nightmare? ;-0). One of the biggest issues, however, is the processes in place do not accurately reflect the business process. This got me thinking about how IT can add value to business by creating proper processes. That is the purpose of this blog entry. To make it more real world, I am going to show the concepts in the form of case studies. Case StudiesCase Study #1: Programming GPS UnitsA GPS tracking company had a need to program units. Initially, this was done by using a terminal program and a script. One of the engineers (equipment engineer, not software engineer) created a program to more quickly push the script to multiple units. The IT department inherited this program and was asked to make it more flexible. The task at hand was to program the unit and track which script the unit was programmed with. In the process of programming, IT noticed two things:
Lesson 1: Storing Data and MetadataWhen the system was envisioned, the unit scripts were “tokenized” and the metadata for each unit was stored in a database. While this was not seen as important at the time, it became an invaluable in troubleshooting units that were sent out. In some cases, the unit was programmed weeks before being shipped out and had an older script. In the interim between programming and shipping, a bug fix was introduced. Prior to instituting this system, units would have to be pulled from vehicles and shipped back to the company, creating an expense for the company. With the script being tracked, along with the metadata, engineering could send out an over the air command to update the “firmware” to the latest specs. Another benefit to storing this metadata was being able to proactively set up a fix on units shipped out in bulk that had bugs. Since the unit numbers could be easily identified, the system could be set up with a “when this unit first reports in, send out a fix” type of command. What IT was doing, in this case, was refactoring out duplication. The main difference between the normal refactoring out duplications, is the duplications here were not in the code. It is a fairly common practice, in good IT shops, to refactor out duplicates in code. For example, if you find two routines that contain data access code, you create a new routine that both of the original routines call. One quick example is when you edit data on a web form. The original bits will end up looking this this: protected void Page_Load(object sender, EventArgs e) protected void EditButton_Click(object sender, EventArgs e) The fix is moving out the binding bits, more like this: protected void Page_Load(object sender, EventArgs e) protected void EditButton_Click(object sender, EventArgs e) protected void BindPage() The scripts were a bit different in the fact they were just AT commands send to a unit, but the original might look like this: AT$Friend = 10.0.0.2 Refactored it would look like this: AT$Friend = {IP_Address} The process is the same as refactoring code, but the metadata is then stored as a set in a database and the unit number is tagged with that set. Summary of lesson: Refactoring is as important for business processes and data as it is for code. NOTE: I will have to cover IT that does not refactor code on another day. ;-) Lesson 2: Store Information Returned From Other SystemsWhen a unit was programmed, it returned certain data, such as the manufacturer’s revision number, manufacturer’s firmware set, etc. Prior to IT working on the programmer, none of this data was stored. And, it was not considered important, for some reason. After the programmer application was coded to store the data, the manufacturer discovered a problem with their own firmware that had to be fixed. Units on the shelf could then be identified as needing the fix and upgraded selectively, rather than attempt to upgrade firmware on all units. It also allowed the company to selectively recall units based on firmware revision, rather than recall all units of that type purchased within a certain time period (the only other way of determining faulty units). Summary of lesson: One thing I have learned in my 15 years of IT is business often does not realize what it is getting from other systems. Data is often flagged as not important without fully ascertaining the business value of the data. I am not suggesting you go around business and store data they have demanded you not store, but rather that you do the following:
Case Study #2: Financial ReportingA credit card processing company needed some financial data to help market their portfolio. The data came from end of month processes. In the process of reporting, the numbers were found to be off in many cases. Looking further, it was discovered that there was no firm way to track what had been reported, making it nearly impossible to get a completely accurate set of numbers. Lesson #1: Flag Data Used in ReportingTransactional data and reporting data are two different things. An individual transaction is stored to make sure every process related to the transaction can be repeated. But, when one reports from transactional data, there is a potential of not being able to repeat a report. In financial reporting, one potential issue is inherent in the process. NOTE: I probably have the names of the bits wrong here, but I am looking at this as a non-financial expert.
This is a bit of an oversimplification of the process. Now, at the end of the month, all of the processing companies send out bills. The terminal processor has to bill the merchant (which is done via ACH from the merchant account, but that is not really important). What is important is that the monthly bill be sent out to the merchant. What is normally done is records between X and Y dates are processed to make up the bills for the merchants. The problem with this approach is a merchant can forget to settle a batch at night. If the batch was created on 6/30 and he comes in on the morning of 7/1, the monthly process may have already been run for billing prior to the records entering the system. If you rerun the report, it will include these records, however. The solution to this problem is to add some type of flag to the system to indicate it has been run on a particular month’s month end process. This makes a for a repeatable process, as you report off records flag, not the date range. This means on the first reporting cycle, you have a pre-process that flags the records to be included. If business asks for a re-run to completely recalculate the numbers, you reflag the records to include any the merchant has processed late. But if they just want the numbers rerun for other reports, you respect the original flag. You now have a repeatable process. Summary of Lesson: It is up to IT to include flags in processes that have consolidated reports. This ensures the same transactions can be used to repeat the reporting process, as well as report other numbers back to business. Once again, if business states this is not important, make sure you document the statements, as this one will come back to bite you some day. Create reset scriptsI have a particular case in mind for this, but I am not sure setting this one up as a case study makes sense. Here is the background: I am currently setting up some financial reports based on month end data (consolidated data, not the original transactions). There are some numbers that are run from other data points. In particular, I have to determine the expenses related to transactions. To make things easier, I have pulled the data from a variety of Access databases (don’t ask) into a single SQL Server table. I then added some columns to store the calculated data. Example: As numerous scripts are run to get the totals, I have set up the following script so I can start back at square one when the calculations are revised. The X, Y and Z are obfuscations of the actual column names, as is EndOfMonthTable (no need giving away any secret sauce ;-0): /* ALTER TABLE EndOfMonthTable update EndOfMonthTable In this case, I have multiple ways of resetting. I can completely delete the columns, rebuild them. Or I can simply zero out the columns. The point here is I have multiple ways to go back in time, depending on my needs. The actual names are obfuscated here, but the process is what is important, not how my employer does business. This is very similar to the rule “you must use source control” and in the case of the actual code I have it stored in SourceSafe (not my choice, I might add, but it is better than no source control). SummaryHere is a quick summary of the lessons learned from the case studies:
Hope this helps! Peace and Grace, Twitter: @gbworld June 12 Back to Basics: The ABCs of Development A = AlgorithmI have been grousing lately about how ill prepared today’s developers are. In particular, I have been ranting about how developers today do not know the basics of development. Rather than simply bitch, I decided to put my foot into the water and start teaching people. This particular article stems from a book idea I have that I will likely be writing soon (really this time). The ABCs I am going to cover over the next few days are: A = Algorithms (this article) From an logical architecture standpoint, C is the most important. From a physical architecture standpoint, B is the most important. But from a developer competency standpoint, it could be argued A is the most important, so here we go. AlgorithmMerriam Websters defines algorithm as:
: a procedure for solving a mathematical problem (as of finding the greatest common divisor) in a finite number of steps that frequently involves repetition of an operation ; broadly : a step-by-step procedure for solving a problem or accomplishing some end especially by a computer We will use the last part of that definition and see an algorithm as a step-by-step procedure for solving a problem or accomplishing some end. As computers only see 0s and 1s, the rest of the definition technically fits, but it leads to confusion as we deal on a higher level of abstraction in our daily work. A Sample AlgorithmSo, let’s suppose our “problem” is multiplying two numbers together, which we will call factorA and factorB. The signature for this method will end up something like the following:
The guts of this method is the algorithm. I assume we all know that this can be resolved rather easily by returning factorA * factorB, but knowing multiplication is simply continuing to add the first factor until we do it factorB number of times. In other words 5*5 is simply 5+5+5+5+5 or five added five times. Following this logic, we might do something like this:
What is wrong with this algorithm? For the consumer of the class? Nothing. They do not see the internals. We could place this code out into production and it would deliver the correct answer. The code is well encapsulated, which means it is completely contained and “hidden” from the consumer. ASIDE: Encapsulation is one of the fundamental concepts of Object Oriented Programming per Wikipedia, which defines it as “Encapsulation conceals the functional details of a class from objects that send messages to it.” There are two problems, from our standpoint.
We will now drift a bit from algorithms to refactoring. Refactoring the AlgorithmRefactoring is altering the code base to improve it. In our code, the do loop is not the best performer. But it has an even larger problem. The intent of the code is not clear. A do loop is generally used to indicate the need to continue to perform a task (or tasks) until a certain condition is met. For example, we might have a do loop that checks to see if a file transfer is completed and when it is, it does work (yes, I know there are better ways of doing this in event driven programming, but roll with me until I think of a better reason for the do loop). If we want to make the intent clearer, we use a for loop, as in the following code snippet:
We now can see that the intent here is 5*5 = 5+5+5+5, as a for loop is terminated after a set number of loops (in this case, 5, as factor B is 5). This solves the clarity problem, but the first time I coded this, I found it actually ran slower. We will get back to this in a moment. Here is a simple test for looping.
We have solved the clarity problem, but we can still improve the algorithm even more. In fact, the end algorithm is likely the one most of us would have started with in the first place, as shown below:
Before moving into the next section, I need to write an aside. It should be noted that refactoring without tests is not a good idea. With small bits like this, we are probably safe. But most of the algorithms we write are a bit more complex and deal with less concrete problems. In addition, we often have routines calling other routines, creating very complex interactions. I have actually written a simple test surrounding this routine, which looks like this:
The test here uses a bastardized form of BDD (Behavior Driven Development), so don’t get caught up in the naming. I can cover TDD versus BDD (and my own bastardized attempt using a unit test framework for BDD, but that will be later). The takeaway with this test is I can verify that each of the algorithms works correctly. Just keep this in mind: refactoring without tests is a dangerous endeavor. And, since so few have tests surrounding their code, perhaps that is why so few people actually spend time refactoring? I am sure there are other dynamics, like management’s thinking that refactoring is paying twice for code, etc. , but that will have to wait for another day and another blog entry. Choosing an AlgorithmWhen I look at Microsoft forums, I generally see people asking questions like this: Which works faster, a FileStream or BinaryStream? ASIDE: The answer, is “it depends”. In general, if you can use binary, it will be faster. But if you are converting to text, you may find binary streaming plus conversion is slower than just using a file stream. The entire conversation surrounds performance. But there are other considerations when choosing an algorithm. In our multiplication example, we refactored primarily for clarity, with the added benefit of greater performance. But, there are instances where you actually lose some performance for clarity. Many years ago, I was tasked with determining the best path to go with a company’s web development efforts. The idea was to focus on the web first and then possibly apply the standardize all types of development to the same standard. I looked at a variety of factors, including the following:
There were other factors, as well, but you get the idea. In the end, I determined Visual Basic, using COM, was our best bet, with ASP as the UI technology. This sparked a debate with another programmer, who favored C++. His primary argument was C++ runs faster than VB. I could not argue against the performance characteristics, as C++ is noticeably faster than VB COM. I did, however, argue that VB, in our testing, was well below the bar in terms of maximum time to complete tasks. His insistence that performance was king led the company to spend around $50,000 to have a consulting firm reach the same conclusion. From a personal standpoint, I think you should try to learn what performs the best. Finding ways to get better performance makes you a better developer. You should also learn many different algorithms for the same problem and when to use each one. This brings us to the second point on algorithms: From a practical standpoint, however, maintenance costs business far more money than performance. Why? If the code base is not maintainable, you have to hire all rock stars, which come with a big price tag. As rock stars are not fond of maintenance, you also have a bit of a revolving door problem, which cost the company even more. If the code is easy to maintain, you can hire rock stars for the hard parts and hire mid-level developers for the other work. There are exceptions to this rule, of course. If you are working for Google, high performing algorithms will win as long as they are scalable. But most of us do not work for Google, or a company that does anything near their level of scale. If you can create a highly maintainable system with high performance algorithms (very possible when using framework classes to perform work), then you have a win-win. But, when you must make a decision, maintainability should win the day more often than performance. This is not a hard, fast rule, of course, but I have found it is true in most places where I have worked or consulted. SummaryIn this blog entry, I covered algorithms, the A in our development ABCs. In the process, I touched on a couple of other topics:
In the future, I will hit Boundaries and Contracts. I am not sure whether I will choose B or C first, as Contracts are extremely important in my world. Here are some future ideas for the Back to Basics blog entries:
if you search my blog, you will see I have already covered string concatenation versus a StringBuilder (better performing and more maintainable). Peace and Grace, Twitter: @gbworld June 05 The Case Against Homeschooling – A ResponseThis is a response to a blog entry entitle The Case Against Homeschooling. For the record, so you can try to determine where my bias might lie, my wife and I decided two years ago to homeschool our children. We have a list of reasons, but our primary reasons were as follows:
The article listed 10 items the author felt made a case against homeschooling. I have copied the blog entry, in toto, with my comments added. The original is in red and my comments are in green. Homeschooling: great for self-aggrandizing, society-phobic mother…… but not quite so good for the kid. I tend to discount any argument that begins with an ad hominem, as any argument based on a logical fallacy is a fallacious argument. In forums, the ad hominem is generally a sign that the person presenting the argument has lost and is resorting to name-calling. Considering your stated education level, you might want to consider the use of logical fallacy in any follow up post. Here are my top ten reasons why homeschooling parents are doing the wrong thing: 10. “You were totally home schooled” is an insult college kids use when mocking the geeky kid in the dorm (whether or not the offender was home schooled or not). And… say what you will… but it doesn’t feel nice to be considered an outsider, a natural outcropping of being homeschooled. This item makes a hasty generalization. There is an underlying assumption that homeschooled children, as a rule, are not socialized, making “geekhood” a “natural outcropping” of their schooling. As the author has shown disdain for homeschooling (item #5), I would question how many homeschooled children the author has queried to make this assumption. I would argue we are dealing with a biased sample, which is another logical fallacy. In my experience, this is not the case. While homeschooled students do not get day-to-day socialization with public school children, homeschooled children do participate in a wide variety of activities. As an example, my own children have the following activities throughout the year:
Other homeschooled parents have children that participate in organized sports, either through city leagues or through umbrella school programs. But, destroying the underlying assumption that homeschooled children are not socialized (which you use in other items in your list) is not sufficient to completely destroy the point. There is also the underlying assumption that parents should shield their children from anything that might get them mocked. While I risk making a slippery slope argument here, it is impossible to shield your children from all mockery. And, I would state, that an attempt to do so would reduce the richness that makes life worth living. Imagine if we stopped our children from taking music, as they might be mocked as band geeks. Or if we stopped them from engaging in computers, as they might be called computer geeks. Or, going to the more base nature of man, imagine if we stopped our minority children from attending any activity in which some child might call out a racial slur. If increasing my child’s likelihood of excelling at life means they might be called names by crass people, then it is a risk worth taking. Schooling, even college, lasts for such a short time that it should not be a major factor in any decision about schooling, homeschooling or otherwise. it would be better to mitigate the risk by adding activities than to put a child in public school merely so they can avoid being called a “geek”. 9. Call me old-fashioned, but a students’ classroom shouldn’t also be where they eat Fruit Loops and meat loaf (not at the same time I hope). It also shouldn’t be where the family gathers to watch American Idol or to play Wii. Students–from little ones to teens–deserve a learning-focused place to study. In modern society, we call them schools. If the case is being made that a student should not learn in a building where lunch is served or there are activities other than learning, then all schools, including traditional schools, are being argued against, as lunch, phys ed, computer labs and playgrounds exist in every school in the nation. If the case is that students should not eat or play in the same room they learn in, the author is once again using a biased sample. Most, if not all, of the credible homeschool sources suggest homeschooling in a separate space from the living or dining room. And while not every parent I know has the luxury of setting aside a separate room, a great majority of parents I know do have a separate space for homeschooling, even if it is a specific side of a room that is used for other activities. Even when this is not the case, the child has a separate time for learning that does not involve eating or playing Wii, even by siblings who have completed their daily learning activities. 8. Homeschooling is selfish. According to this article in USA Today, students who get homeschooled are increasingly from wealthy and well-educated families. To take these (I’m assuming) high achieving students out of our schools is a disservice to our less fortunate public school kids. Poorer students with less literate parents are more reliant on peer support and motivation, and they greatly benefit from the focus and commitment of their richer and higher achieving classmates. The underlying assumption here is highly educated students have a big impact on those less fortunate. According to studies, this is possible, but only when the school engages in peer learning activities. Conversely, there are many studies that show parental involvement is a much greater factor in success of the student, as it helps in the areas that make the biggest impact (according to the review Family, School, and Community Influences on Children’s Learning):
In my own experience, my children are currently above grade level in every subject. My oldest is reading 3 grade levels above her current grade and is a grade or two above her level in every other subject. Even if I were to take the argument at face value, I wonder if it would be wise to have her live up to less than her full potential for the “good of the many”. As the assumption is only fully valid in learning environments that include student collaboration (which is more common at college level than grade school level), I question whether removing my child is selfish at all. Furthermore, the decision to homeschool requires a huge sacrifice on the part of the parent. While the action might be selfish to others (not established), it is certainly not selfish when viewed in the light of economic and time sacrifices necessary to properly homeschool one’s own children. 7. God hates homeschooling. The study, done by the National Center for Education Statistics, notes that the most common reason parents gave as the most important was a desire to provide religious or moral instruction. To the homeschooling Believers out there, didn’t God say “Go therefore and make disciples of all nations”? Didn’t he command, “Ye shall be witnesses unto me”? From my side, to take your faithful children out of schools is to miss an opportunity to spread the grace, power and beauty of the Lord to the common people. (Personally I’m agnostic, but I’m just saying…) According to the 2003 study (Homeschooling in the United States, 2003. table 4), the most common reason for homeschooling was “concern about environment of other schools”, with 85.4% of respondents stating this reason. Religious reasons was number 2, with 72.3%, followed closely by "dissatisfaction with academic instruction at other schools". The most important reason in this study was “concern about environment of other schools”, at 31.2%, with religious or moral instruction at 29.8%. While religious/moral reasons were a concern, they were not, as you have stated, “the most common reason”. According to the 1999 study (Homeschooling in the United States, 1999, table 4 - p11), the most common reason for homeschooling was “can give a child better education at home), with 48.9% of respondents stating this reason. Religious reasons was not even close at 38.4%. Even including the standard error, religious/moral reasons cannot be stated as “the most common reason”. I am not sure why you stated religious/moral training was the most common reason, as it is not supported by the studies. I would assume a bit of ignorance on your part, as the other option is you willfully ignored the facts to make your point. 6. Homeschooling parent/teachers are arrogant to the point of lunacy. For real! My qualifications to teach English include a double major in English and education, two master’s degrees (education and journalism), a student teaching semester and multiple internship terms, real world experience as a writer, and years in the classroom dealing with different learning styles. So, first of all, homeschooling parent, you think you can teach English as well as me? Well, maybe you can. I’ll give you that. But there’s no way that you can teach English as well as me, and biology as well as a trained professional, and history… and Spanish… and art… and counsel for college as well as a school’s guidance counselor… and… and… The fallacy here is known as argumentum ad verecundiam, or an appeal to authority. While credentials are useful in determining a person’s qualifications to perform an action, they do not mean that the person is particularly good at performing the action. There is also three unproven underlying assumptions:
I will cover each of these assumptions in order. On assumption #1: In general, homeschooling is focused on curriculums that encourage students learning to teach themselves. While there is a lot of hands on learning in the early years, the student becomes more independent over time. The parent, like any other teacher, must prepare for lessons, to be able to properly grade the assignments. But, most homeschoolers use some form of formalized curriculum, especially in subjects where they are not an expert. On assumption #2: I have already covered this a bit in the last paragraph. The curriculums used by most homeschoolers are formalized and created by experts. Many of the curriculums used in homeschooling are also used in traditional schools, although the layout of the lessons is different due to difference in environment and teaching methods (homeschooling is one-on-one, while traditional school contains more lecture time). On assumption #3: While professors in colleges are required to be experts in the field they teach, the legal requirements for grade school are generally focused more on education coursework than expertise in their field. I can name many cases, locally, where the teacher has a strong interest in the subject rather than formalized teaching. As such, your argument runs against you on the grade level, at least in some cases.. 5. As a teacher, homeschooling kind of pisses me off. (That’s good enough for #5.) This sounds more like your problem than an argument, as it is an appeal to emotion, at best. 4. Homeschooling could breed intolerance, and maybe even racism. Unless the student is being homeschooled at the MTV Real World house, there’s probably only one race/sexuality/background in the room. How can a young person learn to appreciate other cultures if he or she doesn’t live among them? There are two assumptions here
On point #2: While it is true public school children do come in contact with more races and sexual orientations, this does not mean they become more tolerant or less racist. Racism is still a huge problem in our traditional schools, as is intolerance. The one potential benefit to traditional schools, in this regard, is the students are more readily subject to public punishment for expressing racism or intolerance. The word “public” is very important in my last statement. My experience, however, has been that my children’s activities in her homeschooling career have the same racial mixture as they did in their public school career. This may not be true for all parts of the country, however. 3. And don’t give me this “they still participate in activities with public school kids” garbage. Socialization in our grand multi-cultural experiment we call America is a process that takes more than an hour a day, a few times a week. Homeschooling, undoubtedly, leaves the child unprepared socially. I will agree with you that this is just a few hours a week for most homeschooled children, but you have provided no evidence that this leaves a child “unprepared socially”. In fact, there are numerous studies showing that homeschooled children, despite only a “few hours” of socialization, "gained the necessary skills, knowledge, and attitudes needed to function in society...at a rate similar to that of conventionally schooled children". In fact, one study of adults who had been homeschooled found their “socialization was often better than that of their [traditionally] schooled peers”. 2. Homeschooling parents are arrogant, Part 2. According to Henry Cate, who runs the Why Homeschool blog, many highly educated, high-income parents are “probably people who are a little bit more comfortable in taking risks” in choosing a college or line of work. “The attributes that facilitate that might also facilitate them being more comfortable with home-schooling.” More comfortable taking risks with their child’s education? Gamble on, I don’t know, the Superbowl, not your child’s future. We all take risks in life. Not all of the risks involve gambling; the majority, in fact, are reasoned, calculated risks. When one examines homeschooling versus public education, the numbers show that homeschooled children do as well, if not better, in nearly every metric used to grade differences. 1. And finally… have you met someone homeschooled? Not to hate, but they do tend to be pretty geeky***. *** Please see the comments for thoughts on the word ‘geeky.’ But, in general, to be geeky connotes a certain inability to integrate and communicate in diverse social situations. Which, I would argue, is a likely result of being educated in an environment without peers. It’s hard to get by in such a diverse world as ours! And the more people you can hang out with the more likely you are to succeed, both in work life and real life. I have found there are homeschool geeks, as well as traditionally schooled geeks. Barring some study that shows a higher level of geekiness in homeschooled children, I will take this point for what it is worth: Nothing. One last note, to those homeschooling parents out there: it’s clear from the number and passion of your responses that TeacherRevised is missing an important voice in the teaching community. If any of you are interesting in writing for us, send me an email: jessescaccia@gmail.com. I would love to have you as part of our conversation. Based on your rant here, I am not sure you really want to hear a homeschool parents voice. If you would really like to hear one, I have given you my email so you can respond. Hopefully your response will be better researched and thought out than this long-winded ad hominem. If you want a conversation, I would entertain it. If you want to make me a butt of a joke, as you seem to have attempted here, I would rather bow out. Overall, homeschooling is working. So well that more and more states are opening public school facilities to homeschoolers to help in the education of these children. So well that more and more colleges are not only allowing homeschooled students to join their ranks, but are seeking them out. So well that more and more parents are turning to homeschooling as an option (estimated 850,000 in the 1999 study, 1.1 million in the 2003 study and 1.5 by 2007 – perhaps double by the time the numbers are calculated for 2009). While I respect the author’s zeal for traditional education, there is no evidence shown that any of the assertions made in the “case” are correct and the liberal use of logical fallacy makes me wonder whether this was truly an attempt to make a point or merely a chance to rant against something the author did not like. Peace and Grace, Twitter: @gbworld June 01 Immunotherapy working against cancerI just read this article and see that boosting the immune system is working against cancer. It appears we are finally making headway with the idea that boosting the immune system will kill cancer. And I think this is a great thing. But I am a bit pissed off about the way it is being handled. I am going to cover quite a few topics, and this one may ramble a bit, but I think it is very important to have these conversations. BackgroundFor those who are not aware, my daughter Miranda (now 5) was diagnosed with Ewing’s Sarcoma, a rare childhood cancer, in September of 2007. We opted for standard treatment. Ewing’s has about 250 victims each year, most boys between the age of 10 and 19. Miranda had an Askin’s tumor, which is a soft tissue form of Ewing’s, which normally appears in the bone. Her form of Ewing’s only hits about 25 people per year. During our treatment, we opted for a few complementary treatments. Examples:
This is not science, however, as a case study of one is anecdotal. I will get back to this in the next section. The Daniel Hauser CaseIf you are not aware, Daniel Hauser is the child who is being forced to take chemo. Daniel was diagnosed with non-Hodgkins lymphoma and completed one round of chemo. Then he and his parents decided they wanted to try alternative methods. Child services stepped in and got a court to force chemo on Daniel, so he and his mother fled, with a desire to go to Mexico for alternative treatments. I am a bit torn on this one, as I would personally opt for conventional treatments, as Hodgkins is very survivable using them. But, I think they should have the option of choosing their medical care. What ticks me off is the media’s statements that Daniel has a 95% chance of survival with chemo and a 5% chance of survival with alternative treatments. I am not arguing the 95% number, as that stat is correct. I am arguing against the 5% number, however, as they have no freaking clue what the true percentage is. I will get back to this after the next section. The family was stuck between the proverbial rock and a hard place. Here is the matrix: Conventional Treatment (chemo)
Alternative Treatment
Now, let’s look at alternative treatments. Science and Alternative TreatmentsFor the most part alternative treatments are not scientifically tested. There are numerous reasons for this, some of which are iterated below:
Let’s examine garlic for a moment. The glio link with cancer was found a few years ago. Doing research, I found research as early as the 1980s on the chemical pathways for garlic fighting cancer. I believe it was missed due to the prejudice against alternative treatments. In science, garlic is largely being tested only for heart disease, and this is primarily due to years of evidence that people eating more garlic have less incidence of heart disease. The glio link was published in 2007, but did not get much traction in the media until this year. It was an in vitro study (testtube) and there is no definitive proof it will work in vivo (in the body). I have found no evidence of studies in mice yet, but there may be some going on. There are no human trials with garlic yet. I would imagine it will be years, if not decades, before there are any. One problem with garlic against glio is the DAS, DADS, and especially DATS may not cross the blood-brain barrier. But, one of the newer treatments for operable glio is to introduce a chemo wafer after the tumor is removed. Why could we not make a garlic wafer and do the same thing? There is an issue with garlic causing bleeding, but I am sure that can be overcome if someone would do the research. My theory is they want to be able to patent artificially DAS, DADS and DATS before they attempt to trial garlic as a treatment for glio. If it is eventually used, and is successful, the lives of so many would have been lost looking for a profit motive. Please note that I am not taking potshots at the scientific community. There are many hurdles to research, including legal battles (both lawsuits and the FDA). I believe, however, that the patient, who has an almost certain death sentence, should be able to decide. As you cannot go to an alternative treatment center for brain surgery, the option is not available elsewhere. 5% chance of survivalBack to Daniel for a bit. Where did they get the 5% number? The best I can figure, if not just pulled out of thin air, they are using stats on people that survive in alternative treatment centers. The problem with this number is most people only try alternatives after the doctors tell them there is nothing more they can do. This is after years of chemo (aka poisoning) and/or radiation (also poisoning). That 5% survive after their bodies have been so abused is a promising number, if you ask me. What would the percentage be if people went alternative from the start? There might be a clue in people like Michael Gearin-Tosh and David Servan-Schreiber. Geran-Tosh was diagnosed with multiple myeloma in 1992, a cancer with a rather short median survival. Gearin-Tosh refused chemo and went to radical alternative treatments. he finally died in 2004, but not from cancer. Servan-Schreiber was diagnosed with a deadly brain cancer. He went conventional, but eventually radically altered his diet and environment and took efforts to control his stress. he is still alive today, despite a low median survival for his form of cancer. Both of these men are anecdotal evidence, however, as two do not make a scientifically significant case for the success of alternative treatment. You can read their stories in the books Living Proof (Gearin-Tosh) and Anticancer (Servan-Schreiber). What is Cancer? How is it Caused?The truth is we do not completely know the answers to these questions. We do know they are human cells that are out of control that have been genetically altered to avoid the normal cell death pattern. We also know that cancer has the ability to “create” its own blood supply, a process known as angiogenesis. The current “consensus” is cancer is caused by inflammatory processes out of control. We know that some cancers are caused by viruses or bacteria. For example, many GI cancers are known to start from viral or bacterial infections. They have also found that there is a virus association in glioblastoma cells – the HCMV (Human cytomegalovirus). They are not sure what the link is in glio, but the idea of parasites causing cancer is well established in the alternative treatment community, even if the scientific community accepts it for only some cancers. Then again, the science guys might be right on this one. There are a couple of things we know (or at least have shown to a high degree of certainty):
Given what we “know”, it only makes sense that a change in diet, which many alternative therapies focus on, is a good step in increasing survival during cancer treatment and perhaps preventing cancer. ImmunotherapyThe article that prompted this blog entry was about using therapies to help the immune system to fight cancer. Within the past month, a clinical trial on certain types of antibodies proved so effective in neuroblastoma that the therapy has been approved for use in neuroblastoma patients outside of the study. There were six children in the study that developed allergenic reactions that were very serious, but the survival increase potential outweigh the potential of life threatening allergies. What if boosting the immune system with proper nutrition works? The problem is we don’t know. And, this is why the media is reporting a 5% survival potential with alternative therapies for Daniel Hauser, despite the fact there is very little science to support that number. SummaryI am not hacked off with the medical community, per se, but a system that so focuses on pharmaceuticals that it spends precious little money on alternative treatments like food. I do not expect the drug companies to become altruistic on this, as the are businesses. I would, however, like to see more government money spent on determining if alternative therapies hold any promise. This is a sticky situation, however, for a number of reasons.
One potential way of getting real numbers is to take patients who are out of chemo and trying therapies like immunotherapy and comparing them to those going alternative. This would at least give us some real numbers. If the immunotherapy has a 1% survival after the doctors have “given up” on chemo/radiation due to body loads, then alternatives show promise, even at 5%, as they are four times more effective. This might solve some of the ethical dilemma. I am not sure how we will solve this. What if alternative therapies, despite some anecdotal evidence, do not work effectively enough to warrant them? Then again, what if they do? If we could use food as a pharmacy, it would change the medical world as we know it. And humans, in general, resist change. I know this has been a long one, and I thank you for sticking in. For my family, we have greatly altered our lifestyle after my daughter was diagnosed. We have had whole house filtering since long before her diagnosis. But we have gone more to fruits and veggies and eliminated most bagged and boxed foods. The few we do buy are largely organic and we strongly avoid foods with added sugars, especially foods from high omega-6 sources. We do not bring “juices” in the house with any form of added sugars and my children do not drink sodas or kool aid type mixes (including lemonade, gatorade, etc.) in the house, except on very rare occasions. We also have standing “orders” for people outside the home not to give them candy, etc. Is it enough? I don’t know. One thing I am certain of is people in areas of the world without processed foods see less incidence of the cancers plaguing the industrialized world. They do see more GI cancers, which are caused by infections. I will write another entry about Immunotherapy at some time, as the science there is fascinating. If you read the book anticancer, you will see some interesting info on how cancer works to make the immune system not see it as an invader, which is part of what they are working on. Peace and Grace. Twitter: @gbworld |
|
|||
|
|