Disconnected ramblings about software development, iOS, FreeBSD, anti-social networking, kittens, drosophilidae, small business, Android, web services, finches, Windows, electrical engineering, XML, rental cars, rye, or ... FIVE dollars??!... something something beer.

How to use ActivStats for Data Desk with Minitab

So you are taking a statistics course, and the textbook includes a DVD-ROM with ActiveStats for Data Desk, but the course requires you to purchase ActiveStats for Minitab.

The bad news is that ActiveStats for Minitab will cost you another 60 bucks or more.

The good news is that Minitab is an excellent statistics package and it is way better than Data Desk; and if you're willing to make a tiny effort, you don't need to buy ActiveStats for Minitab.

What we are going to do is let ActiveStats open data sets in Data Desk, and then copy-and-paste them into Minitab.

There are two circumstances you will need to do this.

  1. An instructional exercise asks you to plot or analyze something.
  2. A homework assignment asks you to plot or analyze something.

They both work the same way. Let's look at an example.

For every exercise in ActiveStats for Data Desk, there is an equivalent one in ActiveStats for Minitab. They are not always named the same thing, but they are otherwise identical.

In chapter 7-4, there is an exercise called Examine Mortality and Education Using Data Desk. We'll do it in Minitab.


If we click the icon, the exercise is opened in Data Desk.

One of the little windows contains the data set. Select the each of the data columns by holding down shift while clicking each one. Ignore the once called Reference.

Now copy these by pressing Ctrl-C or Edit|Copy Variables. You will be asked if you want the variable names in the first row. Click Yes.

Now fire up Minitab with an empty project. Position the cursor by clicking in the grey cell that is one over and one down. Press Ctrl-V or Edit|Paste Cells. Poof! There is your data set.

Now all you need to do is complete the exercise in Minitab. You may need to use your brain to find the equivalent function in Minitab for each in Data Desk, but they are both statistics software and the terminology is similar or identical.

For this exercise we need to calculate the Pearson Product-Moment correlation, and plot a Scatterplot. Hmmm... I bet Scatterplot is under the Graphs menu... yup. And correlation?

Found it!

Enjoy learning about statistics and sticking it to the man. If this article saved you $60, please consider donating $10 or more to the Guelph Humane Society. The pups and kitties will be grateful.

Server error: '501 5.1.3 Bad recipient address syntax'

A user of my mail server recently had some recipients of a message returned. He received this message from my server.

The following recipient(s) cannot be reached:

       'redacted@civ.utoronto.ca' on 8/20/2014 10:35 AM
             Server error: '501 5.1.3 Bad recipient address syntax'

       'redacted@wlu.ca' on 8/20/2014 10:35 AM
Server error: '501 5.1.3 Bad recipient address syntax' 'redacted@uoguelph.ca' on 8/20/2014 10:35 AM
Server error: '501 5.1.3 Bad recipient address syntax' 'redacted@uoguelph.ca' on 8/20/2014 10:35 AM
Server error: '501 5.1.3 Bad recipient address syntax' 'redacted@eng.uwo.ca' on 8/20/2014 10:35 AM
Server error: '501 5.1.3 Bad recipient address syntax'

The other recipients were delivered successfully. On the server-side, Postfix logged:

Aug 20 14:35:17 darwin postfix/smtpd[63431]: warning: Illegal address syntax from 
or087.uwaterloo.ca[129.97.9.53] in RCPT command: <'redacted@uwo.ca'>
Aug 20 14:35:17 darwin postfix/smtpd[63431]: warning: Illegal address syntax from
or087.uwaterloo.ca[129.97.9.53] in RCPT command: <'
redacted@wlu.ca'>
Aug 20 14:35:17 darwin postfix/smtpd[63431]: warning: Illegal address syntax from
or087.uwaterloo.ca[129.97.9.53] in RCPT command: <'
redacted@eng.uwo.ca'>
Aug 20 14:35:17 darwin postfix/smtpd[63431]: warning: Illegal address syntax from
or087.uwaterloo.ca[129.97.9.53] in RCPT command: <'
redacted@grandriver.ca'>

The problem is that these particular addresses were literally enclosed by apostrophes. I don't know why the user's client (Outlook) misformatted these addresses. He confirmed that he did not copy them from another application or change anything at his end.

To fix the problem I configured Postfix to filter and rewrite the address when it is sending commands to other MTAs.

I added to main.cf:

# Strange filtering
smtpd_command_filter = pcre:/usr/local/etc/postfix/command_filter
and created the file command_filter:
# Fix malformed emails that are surrounded in single quotes.
/^RCPT\s+TO:\s*<'([^[:space:]]+)'>(.*)/     RCPT TO:<$1>$2

This fixed this oddity in which RCPT TO commands were not RFC 821-compliant.

postgrey won't start after FreeBSD upgrade

echo 'postgrey_flags="--inet=127.0.0.1:10023"' >> /etc/rc.conf
chown postgrey:postgrey /var/db/postgrey
/usr/local/etc/rc.d/postgrey start

Oh google

Tags: 

Bicycle engine clutch gear replacement (Part 5: Bearing assembly)

Supplies: New bearings (optional), grease (wheel bearing grease, CV joint grease, or molybdenum grease), degreaser, block of wood
Parts: clutch gear (disc), clutch pads
Tools: arbor press or vise, drill, large socket

  1. Thoroughly clean the bearings and bearing race with degreaser
    Cleaning bearings
  2. Apply enough grease to the race to make it sticky.
  3. Pro tip: If you leave the bearings and race in the magentic part tray for a while, they will become magnetized and will almost assemble themselves.
  4. Install each of the bearings into the race.
    Installing bearings into race
  5. When all bearings are installed, thoroughly coat them in grease. Get it right up in there into their private parts.
    Greasing the bearings
  6. Seat the race into the new clutch disc.
    Installing bearing race
  7. Make a tool like the one shown.
    Press tool
  8. Sandwich the assembly tool, clutch gear, bearing race, flywheel and a large socket together.
  9. Use an arbor press or vise to press the assemblies into place.
    Pressing everything together
  10. Pro tip: Preheat the bearing race with a hot air gun to make it expand before assembly.
  11. Wipe away all excess grease.
  12. Install the clutch pads into the clutch disc.
    Installing clutch pads
  13. Use a wooden block and hammer to seat the pads, if necessary.
    Seating the pads

Bicycle engine clutch gear replacement (Part 4: Repairing gearbox and cover)

Supplies: epoxy putty, Goop, rubber gloves
Tools: flat file, die grinder or dremel, gasket scraper

If this were any other vehicle, most people wouldn't attempt to repair a gearbox in the state, they'd just order replacement parts. Well, the only replacement part for this problem is a new engine, and although I did tell you to buy a spare engine, this break can be repaired.

If you have a TIG welder you might be able to repair this. I would be surprised though, because the metal is of such poor quality, I think it would just evaporate.

I used a combination of epoxy putty and silicone adhesive. Epoxy putty comes in a stick and is sold in a tube under names like JB Weld. It costs about $5-7 a tube. If you chop off a chunk, it will look something like:

Epoxy putty

  1. Use the gasket scraper to remove all remnants. A screwdriver or razor blade can work in a pinch, but be careful. The steel in the screwdriver or blade is harder than the aluminum allow and can scratch or gouge it.
    Gasket scraping
  2. Time to put on the gloves.
  3. As you can see, the two parts of the epoxy are rolled together. To activate the epoxy you thoroughly mix the two parts by smooshing it like playdoh. After about a minute it will start to warm up and is ready to mould. The clock is ticking. In about 5 minutes it will be unworkable.
  4. I split up the putty and moulded it to repair both the gearbox and the cover. The cover worked pretty well, but unlike playdoh the epoxy is not sticky, it is quite dry. I gave up on having it stick in place and instead just made it fit perfectly, as if it were stuck in place. After a few minutes it was hard, and I had a nicely cast piece that wouldn't stay in place.
  5. Goop to the rescue! Goop is a silicone-based adhesive and it is amazing at bonding things that usually don't like to bond, like glass and metal. It comes in gel form in a tube like toothpaste. A tube is about $10 I think. I generously coated the cast gearbox piece in Goop and held it in place for about a minute. It cures quickly once exposed to air.
  6. When both parts were repaired it was time to touch-up the repair. I used a file to smooth the mating edges of both pieces so that they were flat in the same plane as the rest. I test-fitted the gears and there was a bit of interference in a high spot, so I ground it down using an air die grinder.
  7. A few blasts of compressed air cleaned up the job. If successful, the two pieces should mate perfectly (no gaps) and the gears should be able to turn freely.

Bicycle engine clutch gear replacement (Part 3: Clutch assembly and bearing disassembly)

Tools: awl, hammer, magnetic part tray

  1. First we need to split the clutch assembly into its two components: the flywheel and the clutch disc. Use an awl and hammer to gently tap the pieces apart. Do this in the parts tray, because the bearings could spill out at any time.
    Separating the clutch assembly
    Separated halves
  2. The clutch disc and the bearing race should separate easily.
    Bearing race
  3. Collect all the ball bearings. They are very small, and like to hide.

Bicycle engine clutch gear replacement (Part 2: Gear removal)

Getting to the clutch gear

Tools: small flat-head screwdriver

  1. Disengage the clutch and lock it.
  2. Remove the gearbox cover by removing the five Phillips screws.
  3. Remove the flower-but retaining screw with the small flat-head screwdriver.
  4. Remove the flower nut by hand.
  5. Remove the pressure plate and return spring

Removing the clutch gear

Tools: 2 socket wrenches, 14mm socket, two 19mm socket, Super Magic Tool (SMT)

  1. Remove the clutch-lever cover by removing the three Phillips screws.
  2. Remove the 14mm nuts at the gearbox end by using two socket wrenches simultaneously, one on the gearbox end and another on the clutch level end. This will prevent and strong forces from being applied to the chain.
  3. Install the large end of SMT into the clutch gear assembly.
    Installing SMT
  4. Using a 14mm socket, turn the small half of SMT into the large half. It acts as a gear-puller to remove the gear assembly.
    Gear assembly removal
  5. Find the Woodruff key before it is lost, and put it in the magnetic part tray.

Pro tip: If your gearbox exploded like mine did, and the Woodruff key is missing like mine was, the two may have something in common.

Removing the Drive Gear

Tools: Big-ass flat-head screwdriver, SMT, magnetic part tray

  1. Remove the retaining screw with bag-ass screwdriver.
  2. Install the medium size end of SMT into the gear,
    SMT installation in drive gear
  3. Using a 14mm socket, turn the small half of SMT into the large half. It acts as a gear-puller to remove the gear assembly.
  4. Find the Woodruff key before it is lost, and put it in the magnetic part tray.
    Woodruff key

Super Magic Tool (SMT)

Super Magic Tool (SMT)
Pair of wrenches using SMT

If you plan to work on your chinese bicycle engine, you need Super Magic Tool. Technicians call this a Specialized Service Tool, or SST; but I like SMT better. If you bought the engine as a kit, it probably came with SMT. If not, do not attempt disassembly/assembly without it. Pick one up for three bucks.

It is the fucking bees' knees.

The engineers that designed this engine cleverly threaded just about every shaft, passage, hole with one of three sizes of fine threads. SMT can be installed into or over any of these. It is a press, a puller, and an alignment tool, all in one.

Pages

Simple Copyright Policy: If you want to reproduce anything on this site, get my permission first.