Friday, July 18, 2008

Composting for Beginners

It's easy to make a batch of compost your garden will absolutely love!

Compost is decomposed plant material that helps improve your soil by adding organic matter. It helps soil retain water and provides nutrients in a form plants can use easily. Beneficial fungi and microbes in compost also help your plants absorb water and nutrients from the soil. The process of making compost is actually a speeded-up version of what happens naturally on the forest floor or prairie.

Compost starts with equal portions of "greens" and "browns". Organisms that break down plant material use carbon from browns for energy, and nitrogen from greens as food. Typical greens are: fresh grass clippings, chopped garden debris, coffee grounds or manure. Some browns are: fall leaves, straw, wood chips or sawdust (but don't use chips or sawdust from pressure-treated wood). You should be sure grass clippings come from lawns that were not treated with pesticides or herbicides.

Hot Composting

Hot composting is a method that creates compost very quickly. The bacteria that help break down plant material generate enough heat to raise the temperate to as high as 140-160 degrees. This kills most weed seeds and pathogens. A critical mass of at least 3'x3'x3' is needed to really get the decomposition process going.

To begin a batch, first find or build an empty compost bin. Many P-Patches already have bins just waiting for you! Gather and mix equal parts of greens and browns. Fill your compost bin to the top with this mixture, but don't overfill it and never compress the ingredients to try to make them fit. That squeezes out needed air.

As you transfer your mix to the bin, add enough water to dampen it well, but don't drench it. The fungi, microbes and other critters responsible for decomposition need water and oxygen to live. Too much water pushes out all the oxygen, leaving you with a smelly mess! If the batch is too dry, the composting process will slow down or stop. Your compost should be about as damp as a wrung-out sponge.

Cover the top of your batch with a few burlap bags to help retain moisture. Also cover the bin with a piece of plywood to keep out rain and sun.

Tending your Compost

After a few days your new batch of compost will heat up as bacteria start munching away at plant material, consuming oxygen in the process. Fungi will also feast on the fresh mix. These microbes and critters need air to do their work. About once a week, add more oxygen by turning your pile into an empty bin, or if you only have one bin, remove the contents and then put them back in. Try to move the stuff from the top to the bottom, and vice versa. As you turn, add a little water if the mix appears too dry.

Your batch will seem to shrink as the ingredients settle and rot. I like to top off the bin with more fresh mix the first few times I turn a batch.

Your hot compost is finished when it has mostly stopped decomposing, does not heat up between turnings, and looks and smells like dark soil. The initial ingredients should be unrecognizable in the finished product. In summertime, a batch takes about 6 weeks to finish. In winter, it may take as many as 12 weeks. So plan ahead for planting or transplanting time.

As you might have imagined, collecting ingredients for hot compost all at once, then turning the whole batch every week for 6-12 weeks can be tedious and backbreaking work. There's got to be an easier way -- and there is! It's known as cold composting.

Cold Compost

Any dead plant material will eventually rot back to soil. It may take weeks, months, or even years. The only question is how long you're willing to wait, and how much effort you're willing to add to speed up the process. The process where you add plant material as it becomes available (rather than all at once) is called cold composting because the ingredients don't heat up.

You don't need a bin for cold compost -- you can start a pile in a corner of your garden. As you have plant material to get rid of, just add it to the top of the pile. You can chop material by hand, or just throw it on whole. If you find that you have a lot of fresh plant material to add at once, it wouldn't hurt to add some extra browns. The same balance of greens and browns technically still applies to cold compost piles, but you usually don't have so many greens to add at once that restoring the balance becomes a necessity.

Your cold compost will be ready to use in 6 to 12 months. To get to the good stuff, remove the top layer of material that hasn't decomposed yet. Use that un-rotted material as the base for your next cold pile.

Since cold compost doesn't heat up to kill diseases, seeds and rootstock, you will need to be a little more careful about what you put in a cold pile. Don't add weeds that have gone to seed, diseased plant material, persistent roots from berries or vines, or vegetables like tomatoes or potatoes that may sprout in the wrong places.

Trench or Pit Composting

If you don't have a compost bin handy, or don't have room for a cold compost pile, why not try composting underground?

In trench or pit composting, ingredients are buried in holes or a long trench and covered with soil. When you anticipate you will have lots of garden debris to get rid of (like at harvest time), dig a round hole or a long trench between planting rows about 8-12" deep. As you accumulate green material, chop it and mix it with some browns like fall leaves. Drop the mix into your holes or trenches until they're about half filled, then cover it with the original soil you dug out.

It's important not to bury the plant material too deeply since most biological activity occurs in the top 12" of soil. Some gardeners recommend rotating your open and cooking trenches with plantings in a 3-year cycle. However, each pit or trench should be ready to plant over in a few months. If you wish to plant sooner, try peas or beans since they have shallow roots that won't be damaged by the rotting process happening deeper down, and because they help trap nitrogen that might otherwise escape from the decomposing material.

Sheet Composting

Sheet composting is easier than trench composting because there's no digging involved.

Start your sheet compost with a mix of equal parts greens and browns. I prefer mixing the ingredients thoroughly, but you can use several 2-3" layers of greens and browns if that's easier for you. Spread your mixture in an 8-12" overall layer and water it down. You can cover the mixture with burlap bags and wait a few weeks for decomposition to begin, or you can plant directly in the new mix. The layer of materials won't be thick enough to retain heat, so seeds or roots won't be damaged. You can also plant a cover crop over the compost materials. Nitrogen-fixing covers like crimson clover, vetch, or fava beans are the best since they will help capture nitrogen released in the decomposition process. Rye or other grasses won't capture the nitrogen as well as legumes will.

Using Your Compost

Compost acts as a slow-release fertilizer and you can add it to your garden at any time. Before planting in spring, dig lots of finished compost into the soil. As plants grow throughout the summer, mulch between rows with it every few weeks (but leave a little space around plant stems). In the fall, add compost before sowing a cover crop. If you cover your beds in the winter, add compost to let it age well before spring returns.

Copyright © 2004 Brian Ballard. All rights reserved.

Monitoring Your Web Server Logs

In my SEO post, I noted that you should really pay attention to how people are using your site. You can do this with services like the free Google Analytics, or your web hosting provider may provide some traffic analysis tool. Other products that process your server logs are also available.

On my smaller sites, I actually just use Excel to sift through my server logs! Here's how I do it. (My web hosting company uses the Apache web server, so my notes are specific to that type of server.) Here's an example line from my Apache log file:


193.53.87.89 - - [17/Jul/2008:00:51:18 -0400] "GET /index.shtml HTTP/1.1" 200 16640 "http://www.google.com/search?hl=en&q=helpful+information&btnG=Search" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)"


Here's what each bit of that logged data is:

  • Host - 193.53.87.89 - This is the internet address ("IP address") of the site vistitor's computer. Sometimes you'll see a slightly more recognizable web domain name like c-193-53-87-89.hsd1.ga.comcast.net here instead of just numbers.

  • The two dashes are reserved for password-protected pages. If my site were password protected, the dashes would be replaced with the logged-on user's id.

  • Time - [17/Jul/2008:00:51:18 -0400] - This is the date and time when the visitor requested this page from the server. The -0400 is my server's time zone (i.e. 4 hours before GMT).

  • File - "GET /index.shtml HTTP/1.1" - This is the page requested from my site, with the technical name of the request method (HTTP 1.1). When the page is a form that's submitted, you'll see POST instead of GET. When someone's server is just making sure your page is still there, you may see HEAD instead of GET.

  • Code - 200 - This is the technical code for whether the server is returning a page or an error. You're probably familiar with the code 404 for a page not found error. 200 just means, "OK nothing wrong. Here's the requested page."

  • Bytes - 16640 - This is the number of bytes the server delivered. My site's home page is about 16,640 bytes. This number probably won't exactly match your page file sizes because the number includes the size of extra information the servers sends with your page ("headers").

  • Referer - "http://www.google.com/search?hl=en&q=helpful+information&btnG=Search" - This value is the page your visitor was on right before coming to your page. This is really valuable information for a marketer. Most of the time the page is just another page on your own site, but in this case, it tells me that my visitor used Google to search for sites about "helpful information." However, if this value is just "-", then someone used a bookmark to visit your site, or typed your web site address into their browser by hand. More commonly, web indexing spiders often will not provide a referer value and you'll just see "-" here.

  • Browser - "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)" - This big long hairy string contains information about your visitor's web browser and computer operating system. This can be helpful if you want to know whether people are using PCs or Macs to view your site. Web developers can also use this information to be sure your site works well with the various web browsers available.



I download log files daily from my web hosting account using FTP. I usually download the previous day's file, which on my server is called access.yesterday. This is just a plain text file that you could open with Wordpad or Notepad, but it's tough to read through that way.

I open my access.yesterday file in Excel. When Excel's Text Import wizard pops up, I choose Delimited and click Next. Then I unselect the Delimiters button for Tab and select the button for Space. I leave all the other settings alone and click the Finish button.

Now I have a spreadsheet with each bit of log information in a separate column, but the data is still a little messy, and there are no column headings. I used to add a header row, do a lot of cleanup, and sort the data manually, but finally I recorded an Excel macro to do that for me. Here's the macro code; feel free to use it. Again, it only works for Apache server log files. (By the way, change 2008 to the year you're in if you're reading this post from the future!)


Sub Apache_Log_Cleanup()
'
' Apache_Log_Cleanup Macro
' Cleans up an imported Apache web server log
'
'
Rows("1:1").Select
Selection.Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
Range("A1").Select
ActiveCell.FormulaR1C1 = "Host"
Range("D1").Select
ActiveCell.FormulaR1C1 = "Time"
Range("F1").Select
ActiveCell.FormulaR1C1 = "File"
Range("G1").Select
ActiveCell.FormulaR1C1 = "Code"
Range("H1").Select
ActiveCell.FormulaR1C1 = "Bytes"
Range("I1").Select
ActiveCell.FormulaR1C1 = "Referer"
Range("J1").Select
ActiveCell.FormulaR1C1 = "Browser"
Range("B:C,E:E").Select
Range("E1").Activate
Selection.Delete Shift:=xlToLeft
Columns("B:B").Select
Selection.Replace What:="[", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Selection.Replace What:="2008:", Replacement:="2008 ", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Columns("C:C").Select
Selection.Replace What:="GET ", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Selection.Replace What:=" HTTP/1.0", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Selection.Replace What:=" HTTP/1.1", Replacement:="", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False, SearchFormat:=False, _
ReplaceFormat:=False
Rows("1:1").Select
Selection.Font.Bold = True
Range("A2").Select
ActiveWindow.FreezePanes = True
Range("C1").Select
Range("A1").Select
ActiveWorkbook.Worksheets("access").Sort.SortFields.Clear
ActiveWorkbook.Worksheets("access").Sort.SortFields.Add Key:=Range("A:A" _
), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
ActiveWorkbook.Worksheets("access").Sort.SortFields.Add Key:=Range("B:B" _
), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
ActiveWorkbook.Worksheets("access").Sort.SortFields.Add Key:=Range("C:C" _
), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
With ActiveWorkbook.Worksheets("access").Sort
.SetRange Range("A:G")
.Header = xlYes
.MatchCase = False
.Orientation = xlTopToBottom
.SortMethod = xlPinYin
.Apply
End With
Columns("A:A").ColumnWidth = 25
Columns("B:B").EntireColumn.AutoFit
Columns("C:C").ColumnWidth = 25
Columns("C:C").ColumnWidth = 25
Columns("D:D").EntireColumn.AutoFit
Columns("E:E").EntireColumn.AutoFit
Columns("F:F").ColumnWidth = 30
End Sub


Once you run that macro, you'll be able to sort your data in Excel however you want. The macro automatically sorts by Host, then Time, then File to group visits from the same user (or web spider) together. Pages accessed from the same Host generally represent a visit from one user.

Now that your web log data is all cleaned up, you can scroll through it to find any insteresting visit patterns. I like to sort it on Referer so I can see where my visitors found a link to my site, or what terms they used on search engines that turned up a link to my site. If often also sort on File and delete all the rows with images, css, js, xml and other files that aren't web pages. That makes it easier to focus just on visits to your web pages.

Thursday, July 10, 2008

Ad-supported music streaming

Why Ad-Supported Music Won't Work: Blame The Labels

Here's a post on why it's tough to find a market for on-demand streaming: the content prices are too high for online advertising prices. My favorite truism from the post is: "Sites that try to comply with label requests repel users and soon go out of business."

Wednesday, June 18, 2008

The Comparative Price of Oil

As the price of a barrel of oil skyrockets and the value of the US dollar against the euro plummets, I wondered what the price of oil in euro terms was doing. I thought perhaps the steep rise in the price of oil, traded in dollars, might be attributable merely to the falling relative value of the dollar. If when the euro and dollar were closer to parity, 30 euros or 30 dollars bought a barrel of oil, perhaps Europeans were still bidding around 30 euros for a barrel of oil, but that meant US customers had to increase their dollar bids to keep up with the value of the euro. Maybe Europeans were still paying the same in euro terms for a barrel of oil as they had been for a while.

So last month I searched around the internet for historic oil prices, and dollar to euro exchange rates. Then I graphed out the price of a barrel of oil in both currencies from January 1st, 2000 to May 11th, 2008. It turns out a barrel of oil does cost more in both dollar terms and euro terms, though it costs relatively more in dollar terms.



Then I started wondering about other commodity prices compared to oil. I happened to see a TV ad for someone hawking silver investments who claimed a barrel of oil cost the same in ounces of silver terms as it had in the 1970s. So I thought I'd check out the prices of a barrel of oil in silver terms since 2000 too. It turns out the silver investor is right: a barrel of oil still costs a little more than 6 ounces of silver as it did in 2000, though there have been some ups and downs.



So then I wondered if this held for gold too. It turns out gold hasn't held up quite as well as silver in barrels of oil terms. It now takes a little more gold to buy a barrel of oil than it did in 2000.

Thursday, May 8, 2008

Search Engine Optimization (SEO) Tips and Tricks

Here are some SEO (search engine optimization) tips on how to get your band or music site to show up higher in organic searches (i.e. non-paid search results):

1. Think Like a Searcher

What words will your visitors be searching on when you want your site to appear in the results?

Pick keywords (and their synonyms) appropriate for your target audience to use in the content of your site. Focus on medium-specific to very specific terms so there won't be so many other results competing with your site.

Don't use your keywords too many times on a page or a search engine may consider it keyword spam.

2. HTML Elements

Use your keywords in your page TITLE, meta descriptions, in H1 tags, in bold (or strong or em) font, and as hyperlinked text. Use different appropriate TITLE tags on different pages.

Use your keywords in your image file names, directory paths, ALT attributes and TITLE attributes. Use keywords in anchor TITLE attributes.

Most modern search engines ignore the meta keywords tag which is notorious for spam, but that doesn't mean you should not use the meta keywords tag.

If your site has versions of essentially the same page, but with different URLs (like sort order, or different skins), use link rel="canonical" tags in your page headers pointing to a single primary URL. Search engines will apply page rank "votes" from all links to the various versions of your page to the single canonical URL. That increases its page rank density, meaning your canonical page link will appear higher in search results.

Also add other useful link and meta tags various services, like Facebook and iPhone, may recognize.

3. Keywords in URLs

Use your keywords in your page and image URLs if possible (see example below, both go to the same place). Keywords may be in the actual file names on your server, or you could use URL rewriting to convert URLs with keywords into server file names.

http://www.amazon.com/Harry-Potter-Deathly-Hallows-Book/dp/0545010225
http://www.amazon.com/These-Words-Get-Indexed-Too/dp/0545010225

Google prefers keywords in URLs to be in lower case and separated by dashes (-), rather than spaces (which get rendered as "+" or "%20") or underscores (_).

4. Links to Your Site

Google gives your site extra credit for other sites that link to yours. Get other sites, blogs, and discussion forums to link to your site, preferably from hyperlinked keywords. So provide easy-to-copy deep-links or permalinks on each of your pages.

Syndicate your content (e.g. with RSS feeds) so links back to your site appear on other sites.

Provide common social bookmarking sharing links (e.g. Facebook, Twitter, Delicious.com, Digg, Buzz, etc.)

Find content-appropriate Wikipedia articles to link to your site as a reference.

Many search engines honor rel="nofollow" in link tags. If that attribute is present on a site's links, don't bother putting your links there - search engines may follow them to find your site, but they won't consider the link a "vote" for your page in their page rank.

5. On-Site Links

Hyperlink keywords on your own site to other pages on your site, or to your site search. This is why many sites now display "tag clouds."

6. Long Tail Text

Have lots and lots of pages with lots and lots of words. Not every page will get more than 1 or 2 hits ever, but in aggregate the search traffic adds up.

Use HTML rather than PDF or word processor files. Though some search engines will index document formats, some don't. Besides, proprietary document files are harder for visitors to access than HTML anyway.

7. Text Instead of Flash, Images, or AJAX

Render keywords on your site in text, not images or Flash. Search engines have no way of knowing what's in those files.

Search engines don't generally execute JavaScript, so any text available only from AJAX calls is not visible to spiders.

8. Traffic Reports

Monitor your traffic logs or reports. Your Home page may not actually be your site's front door. Make sure search entry pages are relevant to the search terms, and help users who first enter your site from a deeper page find other pages on your site.

Use your traffic reports to see what top search terms people use to find your page or site and update your pages to optimize for the keywords people are actually using to find your site - even if they're slightly different from what you first thought. If Google decides your site is the best place for keywords you didn't expect, optimize for those words. Ride the wave, don't fight it.

9. Spelling Variations

Include some common typos of your brand names and keywords so people who make the same typo in their search see your site in the results. (But see also tip #14.)

10. Make Dynamic URLs Look Static

Make site search look like regular pages with URL rewriting. Search engine spiders won't follow always dynamic or script directory links, or links with query string parameters, because they could result in an infinite number of pages, but if you make the spider think your dynamic page is really static, they'll index them.

For example, make a search URL that is really http://www.mysite.com/cgi-bin/search.cgi?term=lyrics look like this: http://www.mysite.com/search/lyrics. On Apache, you can do that with your .htaccess file:

RewriteEngine on
RewriteRule search/(.*) /cgi-bin/search.cgi?term=$1 [L]


The (.*) part means "take anything that appears here and put it in variable $1". The $1 part means "take whatever was in the first parentheses and put it here." The [L] means this is the last rewrite rule and the server can stop looking for other rewrite rules. Move the [L] to your last rewrite rule if you have more than one.

11. Avoid Frames

Don't use frames! Most search engines can't (or just won't) navigate to sub-frames. And if a searcher clicks through directly to one of your sub-frames, your site probably won't display properly.

12. Sitemaps

Implement a Google Sitemap.

13. Avoid Link Farms

Don't get your link on link-only pages or parked domains. Some search engines penalize sites that appear on these spam pages.

14. Don't be Devious

Use your keywords in real content. Don't put keywords in tiny fonts or in the same color as the background text. Some search engines penalize sites that use non-visible text.

Proliferation of Social Bookmarking

Social bookmarking (saving links for your favorite web pages to a public site) has exploded in the last few years in terms of people using social bookmarking services, traffic to the bookmark sites, and the sheer number of me-too services. Here's a summary of some of the services available, and JavaScript links you can copy so your visitors can promote your pages in their bookmarks.

The Granddaddy of All Social Bookmarking Sites

digg.com - News and web pages. Started out for the techy set, but has expanded to a general interest audience.

Big sites dedicated to social bookmarking

These sites have from 1-3 million visitors per month according to Compete.com:

stumbleupon.com
reddit.com
technorati.com - A blog search engine. Tends to have the techy and science crowd.
del.icio.us - A general interest bookmark service. Acquired by Yahoo!

Portal Sites

All the big portals have added their own social bookmarking services.

bookmarks.yahoo.com - One of Yahoo! three or more mookmarking features. Nothing like focusing your business...
facebook.com - The social networking site for college kids and fresh-outs.
favorites.live.com - Microsoft's MSN followon.
favorites.my.aol.com - AOL
google.com/bookmarks - Google's bookmarking feature.
myjeeves.ask.com - Yet another search engine's bookmarking.
myspace.com - The social network for high school kids.
myweb.yahoo.com - Another Yahoo! bookmarking service.
netscape.com - Another AOL one.

Medium Sized Verticals

These sites focus mostly on social bookmarking and discussion forums, and have between 100,000 and 1,000,000 visitors a month, though not all exclusively to their bookmarking feature:

slashdot.org/bookmark - The discussion site for cranky software developers.
newsvine.com - A general interest user-submitted news links site.
fark.com - News of the weird for the fraternity crowd.
faves.com
blinklist.com
mixx.com
furl.net
segnalo.alice.it
diigo.com

Smaller Bookmarking Verticals

These sites have between 10,000 and 100,000 visitors per month.

ma.gnolia.com
netvouz.com
simpy.com
backflip.com
spurl.net
blogmarks.net
linkagogo.com
mister-wong.de
feedmelinks.com

Band names need numbers

Random thought of the day. It seems there are a lot of popular bands with numbers in their names:

10 Years
112
2 Pistols
2Pac
3 Doors Down
30 Seconds To Mars
311
38 Special
3OH!3
4 Non Blondes
44
50 Cent
Avenged Sevenfold
Ben Folds Five
blink-182
D12
D4L
Day26
E-40
Eiffel 65
Eve 6
Family Force 5
Five Finger Death Punch
Five For Fighting
Jackson 5
Maroon 5
Nine Days
Nine Inch Nails
One Day As A Lion
OneRepublic
Powerman 5000
Seven Mary Three
Sixpence None The Richer
Sixx:A.M.
Sum 41
Tech N9ne
The B-52's
Three 6 Mafia
Three Days Grace
Three Dog Night
U2
UB40