User talk:Drew R. Smith

From Citizendium
Revision as of 08:29, 15 June 2009 by imported>Caesar Schinas (→‎Template:Convert/doc: new section)
Jump to navigation Jump to search

Welcome!

Citizendium Getting Started
Register | Quick Start | About us | FAQ | The Author Role | The Editor Role
A dozen essentials | How to start a new article | For Wikipedians | Other
Home
Getting Started Organization Technical Help Content Policy Article Lists
Initiatives Communication Editor Policy Editorial Council Constabulary
Main Page

Welcome to the Citizendium! We hope you will contribute boldly and well. Here are pointers for a quick start. You'll probably want to know how to get started as an author. Just look at CZ:Getting Started for other helpful "startup" links, and CZ:Home for the top menu of community pages. Be sure to stay abreast of events via the Citizendium-L (broadcast) mailing list (do join!) and the blog. Please also join the workgroup mailing list(s) that concern your particular interests. You can test out editing in the sandbox if you'd like. If you need help to get going, the forums is one option. That's also where we discuss policy and proposals. You can ask any constable for help, too. Me, for instance! Just put a note on their "talk" page. Again, welcome and have fun! Roger Lohmann 12:01, 3 June 2009 (UTC)

Specialist editors

Drew, you are touching on a category that has been called "specialist editor". User: Aleta Curry is one for dogs; you might want to consult with her. As you point out, there aren't any articles now, so the author role is more critical than the editor. Editors start coming into their own when there are multiple authors to be guided. I don't remember if there are any Dog articles approved; I don't think my cats want me to know (they have excellent canine friends, but it's clear who is boss).

I happen to do a good deal of work in commercial fishing, or, more specifically, the electronics associated with it. That quite conveniently falls under Engineering, sometimes Computers, and even Military when the systems derive from warfare. Nevertheless, the articles need to be produced first. I could probably use Editor involvement on something like Vessel Monitoring System if I were to take it to Approval.

In writing about actual fisheries and species, however, even if I were a Food Sciences or Biology Editor, I couldn't approve my own articles, such as the early one on quahog. Perhaps if there are more than one author writing about sea creatures, we indeed need an Editor, which could be from one of the workgroups I just named. I'm not uninterested in the problem you cite, but from a very different viewpoint. Living here on Cape Cod, what editor would approve an article on Cod? Howard C. Berkowitz 05:40, 4 June 2009 (UTC)

Template:Convert

Hi Drew,
I was just wondering what your eventual intention is for Template:Convert - I see you've been creating a lot of subtemplates for it. How will it eventually work?
Please be sure to document it using {{TlDoc}} once you've finished working on it, including a list of all subtemplates, and then add it to the list at CZ:Templates.
Also, I noticed that you've created a couple of odd pages in different languages, such as Pt:Predefinição:Convert/to(-)‎, which seem to be related to this template - for one thing, we don't have templates (or anything else) in languages other than English at present, and for another, if this page is related to the template it should be in the Template namespace.
I realise you're still working on this, so sorry for coming in in the middle... I'm just interested in what you're doing, as one of the people who currently does most template work/maintenance here.
Thanks! Caesar Schinas 07:10, 13 June 2009 (UTC)

The template will convert units of measurement from one to the other. Take a look at the article Gobioides broussonnetii to see the markup for using it, and you'll see what I mean. For the most part I am doing a bit of cut and paste from the wikipedia version of the templates. I am intending to change things up, especially as some of the syntax doesn't seem to be taking well here. I didn't notice any similar templates anywhere on CZ, so I figured no one would mind much.Drew R. Smith 07:20, 13 June 2009 (UTC)
Okay. No, no-one will mind so long as you document the template well, including all subtemplates, add it to CZ:Templates, and clean up after yourself by putting {{speedydelete|REASON|~~~~}} on any templates/pages which you created and then eventually don't use. Especially the pages like the Portuguese one I mentioned above.
I also notice that you've copied several other Wikipedia templates - Template:Mbox, Template:Pp-meta‎, Template:Pp-template‎, and Template:Documentation‎ (there may be others I haven't noticed...).
Please bear in mind that we already have our own equivalent of some of these templates such as Template:Documentation, and others quite possibly have no place here - for example we do not use notices which display on the article page itself, other than speedydelete. I'm not sure what Template:Mbox, Template:Pp-meta, and Template:Pp-template‎, are - but please do look through the templates which we already have before adding more, and consider whether there is a real need for them. In general, we're trying to cut down on the number of templates rather than create more.
But If you reckon those templates are necessary, by all means go ahead. just be sure to document them well, using {{TlDoc}}.
Caesar Schinas 07:32, 13 June 2009 (UTC)
I'm not entirely sure how to do the documentation, but I will figure it out when I'm done with the convert template. The PP templates, and Mbox templates are actually pertaining to page protection, something I don't think we really need here, so I will speedy them when I have completed everything. I didn't realise thats what they were until I was done with it.Drew R. Smith 07:38, 13 June 2009 (UTC)
The documentation one is neccessary, but since you already have an equivalent, I'll just use that one. Do you now off hand what the name of it is?Drew R. Smith 07:38, 13 June 2009 (UTC)
Yes, it's {{TlDoc}}. You just put the whole contents of the template in <noinclude>...</noinclude> tags, then add <includeonly>{{TlDoc}}</includeonly> at the end. If you create your new templates using the form at CZ:Templates, this is all done automatically.
Caesar Schinas

<---Sorry, I was talking about the CZ equivalent of the Template:Documentation that I made.Drew R. Smith 07:45, 13 June 2009 (UTC)

Well, isn't that it? If not, what is Template:Documentation for? Caesar Schinas 07:49, 13 June 2009 (UTC)
You know what? I think that is it. Just a fancier version that adds a nice header to the documentation subpage... I'll speedy this one now, so I don't forget...Drew R. Smith 07:56, 13 June 2009 (UTC)


Drew, please see my experiment with the system I was talking about for this at User:Caesar Schinas/Template:Convert. There are a couple of examples of its use at the top of User:Caesar Schinas/sandbox at present. It currently only works for converting some imperial units to some metric ones, but it would be very easy to expand. Caesar Schinas 10:51, 14 June 2009 (UTC)

Also, another experiment which splits it up into subpages for better maintainability - User:Caesar Schinas/Template:Conv and its subpages, also currently with examples at the top of User:Caesar Schinas/sandbox. Caesar Schinas 14:04, 14 June 2009 (UTC)

Be careful!

Drew, I urge you to be very careful when editing high-use templates such as {{!}} - your edit broke it by introducing a newline after the pipe.
Also, you are creating a vast number of templates which frankly I think are hardly ever going to be used - wouldn't it be better to wait until there is a demand rather than create them just because WP has them? Caesar Schinas 09:59, 13 June 2009 (UTC)

I understand that I am introducing a high number, however they are all tied together. As for demand, there were already pages that were attempting to use the convert template before I came along.
The point of the convert template is to simplify life for authors and editors so that instead of having to do the calculations themselves, they can simply use this template to auto convert the units.
I garuantee I will clean up after myself, and the end result will be that CZ is just a litte bit easier to use. Also, keep in mind that this is a wiki, not paper, so there is no need to worry that I'll "use up all the space".
I had no idea that I broke the pipe template. All I was trying to do was give the template a documentation so people can know what it is used for. Can you show me exactly what went wrong, and how it should have been done, so I can avoid this kind of problem in the future?Drew R. Smith 10:05, 13 June 2009 (UTC)
Ok, I looked at the history, and see what you changed to fix it, however I don't understand what difference that makes. Other templates add the noinclude tags on the same line, what makes that one different?Drew R. Smith 10:07, 13 June 2009 (UTC)
Of course, I realise that you didn't mean to break it... :-) I'm not blaming you at all; we all make mistakes - just saying be very careful on this sort of template. I usually test templates in my sandbox after editing them unless I'm certain that nothing could have gone wrong.
The problem was that when you added the noinclude tags and TlDoc, you introduced a newline after the pipe character and before the noinclude. I have removed this (and also put the pipe character in includeonly tags so that it doesn't show up on the template page, since there is documentation now. Please see this diff for the change I made to fix it.
Doh! Now I see it. Wow, that one little thing really screwed up a lot of stuff...Drew R. Smith 10:24, 13 June 2009 (UTC)
I realise what the convert template is for - I had actually been going to create it myself sometime, but hadn't got round to it yet. I do think that there might be simpler ways of going about it... but since I'm not sure exactly how you're doing it, I'll keep well clear of it until you've finished!
I don't know what most of the other templates you've created are for - they all have rather cryptic names - but in response to your point that some articles already try to use templates we haven't got; remember that this is othen because those articles are copied from WP. We usually just remove those template calls, unless we think such templates are going to be widely used.
Anyway, I'll try no to interfere any more until you've finished what you're doing...
Caesar Schinas 10:16, 13 June 2009 (UTC)
No no, by all means, if you have concerns, tell me. I'd rather hear them, and possibly save myself some trouble, or better yet save you some trouble, than to "go about my work peacefully". Seriously, lack of constructive criticism was one of the reasons I was looking for something other than wikipedia. They usually have pretty good work, but most users are too into there own projects to give any pointers. Unless you broke something, and then the admins are down your throat.
Sorry about the rant. Anyway, point being, I want all the feedback I can get. If you bring up a good point as to why I shouldn't make some templates, or why I should scrap the project, or do it another way, I'll listen. Drew R. Smith 10:22, 13 June 2009 (UTC)

(unindent) Alright, well what I had been going to suggest for {{convert}} was to use nested switches within the main template, and perhaps a couple of subpages with unit definitions, rather than subpages for each conversion. I don't know exactly how I'd go about it, but I might play around with this concept in my userspace later (I tend to develop templates in my userspace unless they're reasonably straightforward).
I hope my explanation about {{!}} made sense. If you have any questions please feel free to ask. Caesar Schinas 10:29, 13 June 2009 (UTC)

I'm not sure what you mean by "nested", but everything else seemes to make sense. I wouldn't really know how to go about that either, which is why I'm just using wikipedia's design (it works for one) and tweak it once I've got it set up.
As for your explanation of the pipe template, you gave a good explanation, but I had to see the diff before it actually clicked.Drew R. Smith 10:34, 13 June 2009 (UTC)
By nested switches I mean switches inside other switches, so you might have a switch for the "from" unit and then for each possible value, a switch inside that for the "to" unit. Or something like that. But if you're happy with the way you're doing it - good! Caesar Schinas 10:39, 13 June 2009 (UTC)
(edit conflict)::Actually, to simplify similar templates down the road, it would be better to leave the switches out in the open. That way other templates that use similar functions can use the same switch, instead of each template having the switch burried inside it somewhere. This also makes it easier to go straight to the problem if something breaks, assuming the person looking for the problem has the syntax knowhow to know what is wrong. If something breaks, and the only repaireman doesn't have a clue, we're screwed with either system! Hopefully this helps.Drew R. Smith 10:41, 13 June 2009 (UTC)
Ok, my above post was a little different from what I assumed you meant by nested, but I think it still holds.Drew R. Smith 10:41, 13 June 2009 (UTC)
Hmmm... I think we're talking about slightly different things. I'm only talking about the actual code which is only used for that template, not stuff which is used in multiple templates. Parts which are used in many templates should, as you say, be in separate templates transcluded onto each template, so long as they will be used in enough different templates to make it worth it. But remember that the more template transclusion going on, the slower the page loads - we already have a bit of a problem with this at CZ due to the way the subpages template works. But don't let me distract you; carry on with your template and then I'll be able to see the final result! :-D Caesar Schinas 10:50, 13 June 2009 (UTC)

Break for ease of use

Actually, I am having a bit of trouble with some of the syntax. Take a look at the page I mentioned again, and you will see this:Template:Rnd/bExpression error: unrecognised word "expression" where a neat little conversion should be. I can't figure out what I did wrong, or if I missed anything. Do you know what causes a message like that?Drew R. Smith 10:55, 13 June 2009 (UTC)

Well, its caused by an invalid expression in an {{#expr:...}} parser function somewhere, but I couldn't say where without studying all of your new templates in depth... which would take a long time! It might be because one of the WP templates you imported relied on another which you haven't imported. This is a problem with WP templates; the tend to be so interdependent that it's hard to copy one without copying loads. I tend to start from scratch rather than copying WP templates directly, though of course I study the WP ones first to see how they work and so forth.
Sorry I can't be more helpful... Caesar Schinas 11:03, 13 June 2009 (UTC)
I figured as much, which is why I just kept plugging along hoping I would finally hit that magic template that makes the conversion pop into place. Thanks for all the help and advice.Drew R. Smith 11:05, 13 June 2009 (UTC)

I'm finally hitting some of the magic templates. Celsius, and feet work, inches works only in some instances. Its a start!Drew R. Smith 12:03, 13 June 2009 (UTC)

Ok, I can't go on any longer tongiht. I gotta get some sleep. I'll be back at it tommorow. The following are notes on my progress, and are more for my personal use: I have isolated the problem to a rounding/fraction issue, however the actual problem isn't located in the Template:Rnd series. WP has close to 2000 subpages for the Template:Convert series. I'm going to try to knock out as many of the actual units of measurement conversions so I can find which function templates I missed in the series.
One other note, I only wanted to make some key conversions, however I can see now that I will have to make every unit right from the start.Drew R. Smith 14:35, 13 June 2009 (UTC)

Conversion of units

Drew, I came to the conclusion quite a while ago that it was more difficult to import WP templates for conversion than just doing the conversions myself. I suggest that you look at these CZ articles I wrote: U.S. customary units and Fahrenheit and Rankine temperatures. For metric units, see SI.

The U.S. and Belize are the only countries that have not converted to the metric system of units. In fact, there are many high school students in other countries who have never heard of the inch, the foot, Fahrenheit temperatures, etc. Milton Beychok 17:57, 13 June 2009 (UTC)

I'm not too worried about the difficulty in importing it. I'm already at least halfway done, and I really don't mind doing it.
Im not too sure what the usage of one unit over the other really has to do with it. The U.S. and Belize may be the only ones, but make up a signifcant portion of our readers (US in particular), while the only (native) english speakers who use metric would be England and some other smaller countries. I think having both units would be particularly useful.
It may be easier to convert it your self than to import the WP conversion templates, but conversions are a repeating phenomina while importing the templates is a singularity. I really dont mind taking on this enormous task when the outcome creates a much easeir to use CZ. I'm also importing all the documentations and instructions on how to use it, so it's not like it won't be used.
Cheers! Drew R. Smith 02:03, 14 June 2009 (UTC)

-- Answered your message on my talk page. Caesar Schinas 08:11, 14 June 2009 (UTC)

Please be cautious about inserting conversion templates when, variously, a reference is deliberately approximate, such as "roughly 100 Feet by 100 Feet", or where there may be specialized customary usage, as in many nautical movements. When I "roughly", it was my intention not to go to multiple significant figures. A conversion with two decimal places, "(30.48 metres by 30.48 metres)" simply doesn't fit the situation.
From sad experience at The Other Place — and I know you haven't done this here — there are places where a customary unit is used in a treaty language (e.g., 200 mile Exclusive Economic Zone), or in a nautical unit such as a nautical mile or a deadweight ton, which has additional constraints that are not expressed in a conversion. A nautical mile maps literally to angular measurement. Howard C. Berkowitz 08:05, 15 June 2009 (UTC)
All your nautical speak is leaving me horribly lost! However I can change it to show no decimals if that is what is needed. The way it was showing up was a big expression error, so even if the context wasn't quite right I think it still looks better than before.Drew R. Smith 08:10, 15 June 2009 (UTC)
Just be cautious when inserting conversion templates into military or nautical text. There may be specific reasons not to convert. A gun caliber may not be just a measurement, but a name. For example, there are articles on various types of 5 inch guns. These are not 127mm guns. In like manner, a 152mm howitzer is not spoken of as a 6 inch. Howard C. Berkowitz 08:24, 15 June 2009 (UTC)
In like manner, when the text speaks of "approximately" or "generally", and no decimals are used, do not add decimals.


Obviously not for the guns. That would just be silly. I've only been going through and replacing {{convert}} with a template that works. As for the specific instance where the measurement was an aproximation, I will remove the decimals. For future reference, for you or anyone else that reads this, to remove the decimals simply change "precision=x" to "precision=0".Drew R. Smith 08:31, 15 June 2009 (UTC)

I have fixed the problemDrew R. Smith 08:44, 15 June 2009 (UTC)

Ombox

Hi Drew,
I see you imported the WP Ombox template. Unless you object, I am going to move it to Template:Message box - at CZ we try not to use cryptic names.
I have actually been standardising the message boxes across CZ templates, with the aim of eventually introducing a template for them, so I hope Ombox is compativle with what I've been doing - I'd been going to start from scratch, and I'd still rather do so.
Also, you should check that all the documentation is applicable to CZ before importingit - the "We are deploying!" section is a case in point... :-p
Caesar Schinas 09:00, 15 June 2009 (UTC)

Eek. Actually Ombox was supposed to be used for the intricate template. It also has a parameter for an image. It probably won't be compatible, at least not without significant changes. Of course, "significant" is misleading, as there really isn't a whole lot of code behind it. If you want the message boxes to be standard, and without icons, I would just speedy the thing and start from scratch. If you do decide to adapt it to your needs, most of the code is actuall at {{ombox/core}}. As for the name change, I couldn't care either way. Usually cryptic names aren't an attempt to disuise the contents, but rather a byproduct of having a lot of similar templates. For instance, wp has ombox, mbox, and several other box templates that all do pretty much the same thing, except in different namespaces. Since we want message boxes to be the same across all of CZ, "ombox" should be changed to something a little easier to identify.Drew R. Smith 09:11, 15 June 2009 (UTC)
Alright; I might just speedydelete it and start from scratch, as you say.
I do understand the reasons for the cryptic names at WP - they just have too many templates. But here we try to have less. I might just call it Template:Box, and then we can have a parameter which makes it a notice box or a warning box or whatever if we want. Caesar Schinas 09:21, 15 June 2009 (UTC)

Speedydeleting Convert templates

Don't bother putting speedydelete on all those; if you can confirm that everything in Category:Subtemplates_of_Template_Convert wants deleting I'll just do it all at once with a bot. Caesar Schinas 10:58, 15 June 2009 (UTC)

Yeah, Everything there needs deleting. Same with Rnd and Scinote. Once your bot kills the bulk, I'll go get any stragglers (templates not covered by a category) and speedydelete.Drew R. Smith 11:00, 15 June 2009 (UTC)
Alright; I'll go ahead. Caesar Schinas 11:00, 15 June 2009 (UTC)
Sorry about all the trouble.Drew R. Smith 11:11, 15 June 2009 (UTC)
Okay. I think I've done all I can with the bot; speedy anything I've left. Caesar Schinas 11:19, 15 June 2009 (UTC)
Theres still Category:Subtemplates of Template Rnd and Category:Subtemplates of Template Scinote. I've been looking through my contribs, and I think everything else would be pretty easy to speedy.Drew R. Smith 11:22, 15 June 2009 (UTC)
Right; I've done the first. The second doesn't exist... Caesar Schinas 11:26, 15 June 2009 (UTC)
Sorry, Category:Subtemplates of template scinote. What a difference a capitalization makes.Drew R. Smith 11:29, 15 June 2009 (UTC)
Done that and a few others I found. Going offline now, but will be back in a couple of hours. Caesar Schinas 11:33, 15 June 2009 (UTC)
Ok. Again, sorry for the trouble. And thats a pretty neat little toy (your bot). I'm not even going to ask how to get one, because I already know the answer. "You'll put someones eye out!"Drew R. Smith 11:35, 15 June 2009 (UTC)

Template:Convert/doc

I've copied the old contents of Template:Convert/doc to your userspace at User:Drew R. Smith/Template:Convert/doc in case you find it useful when creating the new documentation. Caesar Schinas 13:29, 15 June 2009 (UTC)