--- a
+++ b/w.mean.R
@@ -0,0 +1,6 @@
+w.mean =
+  function (x, w) 
+  {
+    wx = w*x
+    sum(wx) / sum(w)
+  }
\ No newline at end of file